﻿        /* ===== Compact refresh: comments, SRS filters, mobile layout ===== */
        .question-comment-card {
            margin-top: 10px;
            padding: 10px;
            border-radius: 20px;
            background:
                radial-gradient(circle at top left, rgba(191, 219, 254, 0.20), transparent 36%),
                linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(243, 248, 255, 0.96) 100%);
            border: 1px solid rgba(191, 219, 254, 0.88);
            box-shadow: 0 18px 34px rgba(37, 99, 235, 0.08);
        }

        .question-comment-head {
            gap: 8px;
            margin-bottom: 10px;
        }

        .question-comment-title {
            font-size: 10px;
            letter-spacing: 0.04em;
            text-transform: uppercase;
            color: #1e3a8a;
        }

        .question-comment-subtitle {
            margin-top: 3px;
            font-size: 8px;
            line-height: 1.55;
            color: #64748b;
            max-width: 360px;
        }

        .question-comment-count {
            min-height: 22px;
            padding: 0 8px;
            border-radius: 999px;
            font-size: 8px;
            letter-spacing: 0.02em;
            background: rgba(255, 255, 255, 0.92);
            box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.86);
        }

        .question-comment-input {
            min-height: 74px;
            padding: 10px 11px;
            border-radius: 16px;
            font-size: 11px;
            line-height: 1.55;
            background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 250, 252, 0.98) 100%);
        }

        .question-comment-actions {
            gap: 6px;
            margin-top: 10px;
        }

        @media (min-width: 769px) {
            body:not(.dark-theme) #setup-section.test-workspace-active {
                background: linear-gradient(180deg, #fff1f2 0%, #ffe4e6 100%) !important;
            }

            body:not(.dark-theme) #quiz-panel.test-workspace #quiz-info-column {
                padding: 6px !important;
                border-radius: 24px;
                background: linear-gradient(180deg, rgba(255, 241, 242, 0.97) 0%, rgba(254, 205, 211, 0.86) 100%);
                border: 1px solid rgba(251, 146, 172, 0.34);
                box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
                box-sizing: border-box;
            }

            body:not(.dark-theme) #quiz-panel.test-workspace #quiz-main-column {
                padding: 8px 10px 24px !important;
                border-radius: 24px;
                background: linear-gradient(180deg, rgba(255, 244, 246, 0.98) 0%, rgba(255, 228, 230, 0.9) 100%);
                border: 1px solid rgba(251, 146, 172, 0.36);
                box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.94);
                box-sizing: border-box;
            }

            body:not(.dark-theme) #sidebar-nav.test-workspace-sidebar #nav-items-container {
                background: linear-gradient(180deg, rgba(255, 242, 243, 0.96) 0%, rgba(254, 205, 211, 0.8) 100%);
            }
        }

        body:not(.dark-theme) #quiz-panel.test-workspace #question-card-wrapper {
            padding: 10px 10px 24px !important;
            border-radius: 24px;
            background: rgba(255, 232, 236, 0.92) !important;
            border: 1px solid rgba(251, 146, 172, 0.26) !important;
            box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9) !important;
            box-sizing: border-box;
        }

        body:not(.dark-theme) #quiz-panel.test-workspace #question-card {
            background: rgba(255, 241, 243, 0.98) !important;
            border: 1px solid rgba(251, 146, 172, 0.42) !important;
            box-shadow: 0 18px 34px rgba(244, 63, 94, 0.1) !important;
        }

        body:not(.dark-theme) #quiz-panel.test-workspace #question-card .question-card-body {
            background: rgba(255, 236, 239, 0.82) !important;
            border-radius: 20px;
            padding-left: 6px !important;
            padding-right: 6px !important;
        }

        body:not(.dark-theme) .question-comment-card {
            background: rgba(255, 230, 235, 0.98) !important;
            border: 1px solid rgba(251, 146, 172, 0.44) !important;
            box-shadow: 0 18px 34px rgba(244, 63, 94, 0.12) !important;
        }

        body:not(.dark-theme) .question-comment-head {
            padding: 10px 12px;
            border-radius: 18px;
            background: rgba(255, 236, 239, 0.96);
            border: 1px solid rgba(251, 191, 202, 0.72);
        }

        body:not(.dark-theme) .question-comment-title,
        body:not(.dark-theme) .question-comment-action-hint,
        body:not(.dark-theme) .question-comment-empty {
            color: #be123c;
        }

        body:not(.dark-theme) .question-comment-title {
            color: #9f1239;
        }

        body:not(.dark-theme) .question-comment-count {
            background: rgba(255, 236, 240, 0.96);
            border-color: rgba(251, 191, 202, 0.96);
            color: #e11d48;
        }

        body:not(.dark-theme) .question-comment-input {
            background: rgba(255, 236, 240, 0.99);
            border-color: rgba(251, 191, 202, 0.72);
        }

        body:not(.dark-theme) .question-comment-input:focus {
            border-color: #fb7185;
            box-shadow: 0 0 0 4px rgba(251, 113, 133, 0.14);
        }

        body:not(.dark-theme) .question-comment-actions {
            padding: 10px 12px;
            border-radius: 18px;
            background: rgba(255, 233, 237, 0.94);
            border: 1px solid rgba(251, 191, 202, 0.68);
        }

        body:not(.dark-theme) .question-comment-empty {
            background: rgba(255, 236, 240, 0.98) !important;
            border-color: rgba(251, 191, 202, 0.78) !important;
        }

        body:not(.dark-theme) .question-comment-footer-spacer {
            border-radius: 18px;
            background: rgba(255, 228, 233, 0.82);
        }

        .question-comment-action-hint {
            font-size: 8px;
            letter-spacing: 0.02em;
        }

        .question-comment-save-btn,
        .question-comment-audio-btn,
        .question-comment-voice-btn,
        .question-comment-cancel-btn,
        .question-comment-item-btn {
            min-height: 28px;
            padding: 0 11px;
            border-radius: 999px;
            font-size: 8px;
            letter-spacing: 0.02em;
        }

        .question-comment-list {
            gap: 6px;
            margin-top: 9px;
        }

        .question-comment-item {
            padding: 9px 10px;
            border-radius: 16px;
            border: 1px solid rgba(219, 231, 243, 0.92);
            background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 251, 255, 0.94) 100%);
            box-shadow: 0 10px 20px rgba(148, 163, 184, 0.08);
        }

        .question-comment-item-badge,
        .question-comment-item-date {
            font-size: 8px;
        }

        .question-comment-item-text {
            font-size: 10px;
            line-height: 1.58;
        }

        .question-comment-item-actions {
            gap: 5px;
            margin-top: 7px;
        }

        .question-comment-empty {
            margin-top: 8px;
            padding: 10px;
            border-radius: 16px;
            font-size: 9px;
        }

        .question-comment-footer-spacer {
            height: 60px;
        }

        #srs-block .srs-filters-grid {
            display: grid !important;
            grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
            grid-auto-flow: row;
            align-items: stretch !important;
            gap: 5px !important;
            overflow: visible !important;
            padding-bottom: 0 !important;
        }

        #srs-block .srs-filters-grid > * {
            min-width: 0 !important;
            width: 100% !important;
        }

        #srs-block .srs-filter-select {
            width: 100% !important;
            min-width: 0 !important;
            height: 30px !important;
            padding: 0 24px 0 9px !important;
            border-radius: 12px !important;
            border: 1px solid var(--filter-pill-border, rgba(203, 213, 225, 0.92)) !important;
            background: var(--filter-pill-bg, #ffffff) !important;
            color: var(--filter-pill-text, #1e293b) !important;
            font-size: 12px !important;
            font-weight: 800 !important;
            letter-spacing: 0.01em;
            box-shadow: 0 6px 14px rgba(148, 163, 184, 0.08) !important;
            appearance: none;
            -webkit-appearance: none;
        }

        #srs-block select.srs-filter-select {
            background-image:
                linear-gradient(45deg, transparent 50%, var(--filter-pill-arrow, rgba(100, 116, 139, 0.78)) 50%),
                linear-gradient(135deg, var(--filter-pill-arrow, rgba(100, 116, 139, 0.78)) 50%, transparent 50%),
                var(--filter-pill-bg, linear-gradient(180deg, #ffffff 0%, #ffffff 100%)) !important;
            background-position:
                calc(100% - 12px) calc(50% - 2px),
                calc(100% - 8px) calc(50% - 2px),
                0 0;
            background-size: 5px 5px, 5px 5px, 100% 100%;
            background-repeat: no-repeat;
        }

        #srs-block #srs-filter-day {
            min-width: 0 !important;
            padding-right: 8px !important;
            font-size: 12px !important;
        }

        @media (max-width: 768px) {

            .question-comment-card {
                padding: 9px;
                border-radius: 18px;
            }

            .question-comment-subtitle {
                max-width: none;
            }

            .question-comment-footer-spacer {
                height: 52px;
            }

            #srs-block .srs-filters-grid {
                grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
                gap: 4px !important;
                grid-auto-rows: minmax(28px, auto);
            }

            #srs-block .srs-filter-select {
                height: 30px !important;
                padding: 0 22px 0 8px !important;
                border-radius: 10px !important;
                border: 1px solid var(--filter-pill-border, rgba(203, 213, 225, 0.94)) !important;
                background: var(--filter-pill-bg, #ffffff) !important;
                color: var(--filter-pill-text, #1e293b) !important;
                font-size: 12px !important;
                box-shadow: 0 5px 12px rgba(148, 163, 184, 0.08) !important;
            }

            #srs-block select.srs-filter-select {
                background-image:
                    linear-gradient(45deg, transparent 50%, var(--filter-pill-arrow, rgba(100, 116, 139, 0.78)) 50%),
                    linear-gradient(135deg, var(--filter-pill-arrow, rgba(100, 116, 139, 0.78)) 50%, transparent 50%),
                    var(--filter-pill-bg, linear-gradient(180deg, #ffffff 0%, #ffffff 100%)) !important;
                background-position:
                    calc(100% - 10px) calc(50% - 2px),
                    calc(100% - 6px) calc(50% - 2px),
                    0 0;
                background-size: 4px 4px, 4px 4px, 100% 100%;
            }

            #srs-block #srs-filter-day {
                grid-column: auto;
                padding-right: 6px !important;
                font-size: 12px !important;
            }
        }

        @media (max-width: 420px) {
        }

        #left-sidebar.app-sidebar-shell {
            position: fixed;
            top: 0;
            left: 0;
            height: 100vh;
            height: 100dvh;
            width: var(--app-sidebar-expanded-width);
            min-width: var(--app-sidebar-expanded-width);
            background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
            color: #0f172a;
            box-shadow: 0 0 0 1px rgba(226, 232, 240, 0.94);
            transition: width 0.28s ease, min-width 0.28s ease, transform 0.28s ease;
            overflow-x: hidden;
            overflow-y: auto;
            border-right: 1px solid rgba(226, 232, 240, 0.94);
            padding: 10px 0;
            scrollbar-gutter: stable;
            scrollbar-width: thin;
            scrollbar-color: rgba(203, 213, 225, 0.98) rgba(255, 255, 255, 0.98);
            z-index: 4600;
        }

        #left-sidebar.app-sidebar-shell::-webkit-scrollbar {
            width: 4px;
        }

        #left-sidebar.app-sidebar-shell::-webkit-scrollbar-track {
            background: rgba(255, 255, 255, 0.98);
            border-radius: 999px;
        }

        #left-sidebar.app-sidebar-shell::-webkit-scrollbar-thumb {
            background: linear-gradient(180deg, rgba(226, 232, 240, 0.98) 0%, rgba(203, 213, 225, 0.98) 100%);
            border-radius: 999px;
        }

        #left-sidebar.app-sidebar-shell::-webkit-scrollbar-thumb:hover {
            background: linear-gradient(180deg, rgba(203, 213, 225, 1) 0%, rgba(148, 163, 184, 1) 100%);
        }

        #left-sidebar.app-sidebar-shell.sidebar-collapsed {
            width: var(--app-sidebar-collapsed-width);
            min-width: var(--app-sidebar-collapsed-width);
        }

        .sidebar-toggle-btn.desktop-only {
            display: none !important;
        }

        .app-sidebar-inner {
            display: flex;
            flex-direction: column;
            min-height: 100%;
        }

        .app-sidebar-top {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 10px;
            margin: 0 14px 12px;
            padding: 0 0 10px;
            border-bottom: 1px solid rgba(226, 232, 240, 0.94);
            background: transparent;
        }

        .app-sidebar-brand {
            display: flex;
            align-items: center;
            gap: 10px;
            min-width: 0;
            flex: 1 1 auto;
        }

        .app-sidebar-brand-logo {
            width: 52px;
            height: 52px;
            border-radius: 999px;
            background: #ffffff;
            border: 1px solid #d6d3d1;
            display: flex;
            align-items: center;
            justify-content: center;
            box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
            flex-shrink: 0;
        }

        .app-sidebar-brand-logo img {
            width: 30px;
            height: 30px;
            object-fit: contain;
            display: block;
        }

        .app-sidebar-brand-copy {
            min-width: 0;
        }

        .app-sidebar-brand-title {
            font-size: 1rem;
            font-weight: 900;
            letter-spacing: -0.02em;
            color: #0f172a;
        }

        .app-sidebar-controls {
            display: flex;
            gap: 8px;
            align-items: center;
            flex-shrink: 0;
        }

        .app-sidebar-control-btn {
            width: 36px;
            height: 36px;
            border-radius: 12px;
            border: none;
            background: #ffffff;
            color: #475569;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
            box-shadow: none;
            touch-action: manipulation;
        }

        .app-sidebar-control-btn:hover {
            transform: translateY(-1px);
            background: #f8fafc;
            border-color: rgba(226, 232, 240, 0.94);
        }

        .app-sidebar-control-btn:active {
            transform: scale(0.96);
        }

        .app-sidebar-profile {
            margin: 0 14px 14px;
            padding: 12px;
            border-radius: 18px;
            border: 1px solid rgba(226, 232, 240, 0.94);
            background: rgba(255, 255, 255, 0.98);
            box-shadow: none;
        }

        .app-sidebar-profile-header {
            display: flex;
            align-items: flex-start;
            gap: 9px;
            margin-bottom: 0;
        }

        .app-sidebar-profile-avatar {
            width: 50px;
            height: 50px;
            border-radius: 14px;
            overflow: hidden;
            border: 1px solid #d8d5d1;
            box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
            flex-shrink: 0;
        }

        .app-sidebar-profile-avatar img {
            width: 100%;
            height: 100%;
            object-fit: cover;
            display: block;
        }

        .app-sidebar-profile-copy {
            display: flex;
            flex-direction: column;
            gap: 6px;
            flex: 1 1 auto;
            width: 100%;
            min-width: 0;
        }

        .app-sidebar-profile-name {
            color: #0f172a;
            width: 100%;
            font-size: clamp(0.6rem, 0.56rem + 0.12vw, 0.72rem);
            font-weight: 900;
            line-height: 1.12;
            letter-spacing: -0.03em;
            white-space: nowrap;
            overflow: visible;
            text-overflow: clip;
        }

        .app-sidebar-profile-role {
            margin-top: 3px;
            font-size: 0.72rem;
            color: #64748b;
            font-weight: 700;
        }

        .app-sidebar-accounts {
            display: grid;
            grid-template-columns: minmax(0, 1fr) minmax(0, 1.32fr) minmax(0, 0.72fr);
            align-items: stretch;
            gap: 4px;
            width: 100%;
            margin-bottom: 0;
            min-width: 0;
        }

        .app-sidebar-account-pill {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            width: 100%;
            min-height: 24px;
            padding: 4px;
            border-radius: 999px;
            border: 1px solid rgba(226, 232, 240, 0.94);
            background: rgba(255, 255, 255, 0.98);
            color: #334155;
            font-size: clamp(0.48rem, 0.46rem + 0.08vw, 0.54rem);
            font-weight: 800;
            line-height: 1.05;
            letter-spacing: -0.01em;
            text-decoration: none;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            min-width: 0;
            flex: 1 1 0;
            box-sizing: border-box;
            transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
            touch-action: manipulation;
        }

        .app-sidebar-account-pill:hover {
            transform: translateY(-1px);
            background: #f8fafc;
            border-color: rgba(203, 213, 225, 0.98);
        }

        .app-sidebar-account-pill:active {
            transform: scale(0.98);
        }

        .app-sidebar-quote {
            position: relative;
            margin-top: 10px;
            padding: 11px 12px 11px 14px;
            border-radius: 16px;
            background: rgba(255, 255, 255, 0.98);
            color: #334155;
            font-size: 0.74rem;
            line-height: 1.5;
        }

        .app-sidebar-quote::before {
            content: '';
            position: absolute;
            left: 0;
            top: 10px;
            bottom: 10px;
            width: 2px;
            border-radius: 999px;
            background: linear-gradient(180deg, #e2e8f0, #cbd5e1);
        }

        .app-sidebar-nav {
            display: flex;
            flex-direction: column;
            gap: 2px;
            padding: 0 12px 12px;
            overflow: visible !important;
            min-height: 0;
            flex: 1 1 auto;
        }

        .app-sidebar-workspace-section {
            margin-top: 10px;
            padding-top: 10px;
            border-top: 1px solid rgba(226, 232, 240, 0.95);
        }

        .app-sidebar-workspace-title {
            display: block;
            padding: 0 10px 8px;
            font-size: 0.72rem;
            font-weight: 900;
            letter-spacing: 0.04em;
            text-transform: uppercase;
            color: #64748b;
        }

        #workspace-nav-items-container {
            display: grid;
            gap: 4px;
        }

        .app-sidebar-link {
            display: flex;
            align-items: center;
            gap: 10px;
            width: 100%;
            min-height: 34px;
            padding: 7px 10px;
            border: none;
            border-radius: 12px;
            color: #334155;
            font-size: 0.84rem;
            font-weight: 800;
            cursor: pointer;
            background: transparent;
            box-shadow: none;
            transition: background 0.18s ease, color 0.18s ease;
            touch-action: manipulation;
        }

        .app-sidebar-link:hover {
            background: rgba(248, 250, 252, 0.98);
        }

        .app-sidebar-link:active {
            background: rgba(226, 232, 240, 0.92);
            transform: scale(0.985);
        }

        .app-sidebar-link::after {
            display: none;
        }

        .app-sidebar-link-icon {
            width: 20px;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            flex-shrink: 0;
            font-size: 0.92rem;
            color: #94a3b8;
        }

        .app-sidebar-link-text {
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .app-sidebar-link-home {
            background: rgba(248, 250, 252, 0.98);
            color: #0f172a;
        }

        .app-sidebar-link-home .app-sidebar-link-icon {
            color: #0f172a;
        }

        .app-sidebar-link-notes {
            background: transparent;
        }

        .app-sidebar-link-todo {
            background: transparent;
        }

        .app-sidebar-link-next {
            display: none;
            background: transparent;
        }

        .app-sidebar-link-srs {
            background: transparent;
        }

        .app-sidebar-link-history {
            background: transparent;
        }

        body.qcm-workspace-active .app-sidebar-link-next {
            display: flex;
        }

        body.dark-theme #left-sidebar.app-sidebar-shell {
            background: linear-gradient(180deg, #0f172a 0%, #111c31 100%);
            color: #f5f5f4;
            border-right-color: rgba(148, 163, 184, 0.18);
            box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.03);
            scrollbar-color: rgba(148, 163, 184, 0.92) rgba(15, 23, 42, 0.38);
        }

        body.dark-theme #left-sidebar.app-sidebar-shell::-webkit-scrollbar-track {
            background: rgba(30, 41, 59, 0.36);
        }

        body.dark-theme #left-sidebar.app-sidebar-shell::-webkit-scrollbar-thumb {
            background: linear-gradient(180deg, rgba(148, 163, 184, 0.95) 0%, rgba(100, 116, 139, 0.95) 100%);
        }

        body.dark-theme .app-sidebar-top {
            background: transparent;
            border-bottom-color: rgba(148, 163, 184, 0.16);
        }

        body.dark-theme .app-sidebar-brand-title {
            color: #fafaf9;
        }

        body.dark-theme .app-sidebar-control-btn {
            background: rgba(15, 23, 42, 0.78);
            color: #ededec;
            border-color: transparent;
        }

        body.dark-theme .app-sidebar-control-btn:hover {
            background: rgba(22, 32, 51, 0.96);
            border-color: transparent;
        }

        body.dark-theme .app-sidebar-profile {
            background: rgba(15, 23, 42, 0.5);
            border-color: rgba(148, 163, 184, 0.16);
        }

        body.dark-theme .app-sidebar-profile-name {
            color: #fafaf9;
        }

        body.dark-theme .app-sidebar-profile-role {
            color: #b7b7b2;
        }

        body.dark-theme .app-sidebar-account-pill {
            background: rgba(22, 32, 51, 0.9);
            color: #f3f4f6;
            border-color: rgba(148, 163, 184, 0.16);
        }

        body.dark-theme .app-sidebar-account-pill:hover {
            background: rgba(30, 41, 59, 0.96);
            border-color: rgba(148, 163, 184, 0.22);
        }

        body.dark-theme .app-sidebar-quote {
            background: rgba(15, 23, 42, 0.62);
            color: #e6e9ee;
        }

        body.dark-theme .app-sidebar-link {
            color: #f5f5f4;
            background: transparent;
            border-color: transparent;
        }

        body.dark-theme .app-sidebar-link:hover {
            background: rgba(37, 99, 235, 0.16);
        }

        body.dark-theme .app-sidebar-link:active {
            background: rgba(37, 99, 235, 0.24);
        }

        body.dark-theme .app-sidebar-link-home {
            background: rgba(37, 99, 235, 0.24);
            color: #dbeafe;
        }

        body.dark-theme .app-sidebar-link-icon {
            color: #b9b8b2;
        }

        body.dark-theme .app-sidebar-link-home .app-sidebar-link-icon {
            color: #bfdbfe;
        }

        body.dark-theme .app-sidebar-workspace-section {
            border-top-color: rgba(148, 163, 184, 0.16);
        }

        body.dark-theme .app-sidebar-workspace-title {
            color: #94a3b8;
        }

        #left-sidebar.app-sidebar-shell.sidebar-collapsed .app-sidebar-brand-copy,
        #left-sidebar.app-sidebar-shell.sidebar-collapsed .app-sidebar-profile,
        #left-sidebar.app-sidebar-shell.sidebar-collapsed .app-sidebar-link-text {
            display: none;
        }

        #left-sidebar.app-sidebar-shell.sidebar-collapsed .app-sidebar-top {
            flex-direction: column;
            margin-left: 12px;
            margin-right: 12px;
            padding-bottom: 0;
            border-bottom: none;
        }

        #left-sidebar.app-sidebar-shell.sidebar-collapsed .app-sidebar-brand {
            justify-content: center;
        }

        #left-sidebar.app-sidebar-shell.sidebar-collapsed .app-sidebar-controls {
            flex-direction: column;
        }

        #left-sidebar.app-sidebar-shell.sidebar-collapsed .app-sidebar-nav {
            padding-left: 10px;
            padding-right: 10px;
        }

        #left-sidebar.app-sidebar-shell.sidebar-collapsed .app-sidebar-link {
            justify-content: center;
            padding: 12px 0;
        }

        @media (min-width: 769px) {
            #main-content>.app-top-banner {
                display: none !important;
            }
        }

        body.dark-theme {
            background: #07101c;
            color: #e5eefc;
        }

        body.dark-theme #main-content {
            background: radial-gradient(circle at top, rgba(37, 99, 235, 0.08), transparent 28%), #07101c;
        }

        body.dark-theme #setup-section,
        body.dark-theme #setup-section.test-workspace-active {
            background: linear-gradient(180deg, #0b1324 0%, #111827 100%) !important;
        }

        body.dark-theme .bg-white,
        body.dark-theme .setup-filters,
        body.dark-theme #options-panel,
        body.dark-theme .options-search-box,
        body.dark-theme #sidebar-nav,
        body.dark-theme .history-sidebar,
        body.dark-theme .history-card,
        body.dark-theme .socials-modern-panel {
            background: #0f172a !important;
            color: #e5eefc !important;
            border-color: rgba(148, 163, 184, 0.22) !important;
        }

        body.dark-theme .bg-slate-50,
        body.dark-theme .bg-slate-100,
        body.dark-theme .bg-blue-50,
        body.dark-theme .bg-blue-100,
        body.dark-theme .bg-gray-50,
        body.dark-theme .option-top-value,
        body.dark-theme .options-toggle-item,
        body.dark-theme .filter-badge {
            background: #111c31 !important;
            color: #dbe8ff !important;
            border-color: rgba(148, 163, 184, 0.2) !important;
        }

        body.dark-theme .text-slate-900,
        body.dark-theme .text-slate-800,
        body.dark-theme .text-slate-700,
        body.dark-theme .text-slate-600,
        body.dark-theme .text-slate-500 {
            color: #dbe8ff !important;
        }

        body.dark-theme .border,
        body.dark-theme .border-slate-100,
        body.dark-theme .border-slate-200,
        body.dark-theme .border-slate-300,
        body.dark-theme .border-gray-200,
        body.dark-theme .border-gray-300 {
            border-color: rgba(148, 163, 184, 0.22) !important;
        }

        body.dark-theme input,
        body.dark-theme select,
        body.dark-theme textarea {
            background: #0b1324 !important;
            color: #e5eefc !important;
            border-color: rgba(148, 163, 184, 0.24) !important;
        }

        body.dark-theme select option,
        body.dark-theme datalist option {
            background: #0f172a !important;
            color: #e5eefc !important;
            font-size: 12px !important;
        }

        body.dark-theme input::placeholder,
        body.dark-theme textarea::placeholder {
            color: #94a3b8 !important;
        }

        body.dark-theme #setup-panel,
        body.dark-theme #setup-content-layout,
        body.dark-theme #years-container,
        body.dark-theme #quiz-panel,
        body.dark-theme #question-card-wrapper {
            color: #e5eefc !important;
        }

        body.dark-theme #setup-search-row,
        body.dark-theme #quiz-info-header,
        body.dark-theme #quiz-side-controls,
        body.dark-theme #study-inline-info-container,
        body.dark-theme .qcm-catalog-loader,
        body.dark-theme .question-stats,
        body.dark-theme .stats-section,
        body.dark-theme .question-comment-card,
        body.dark-theme .answer-inline-review,
        body.dark-theme .filter-selection-panel,
        body.dark-theme .révision-filter-dropdown,
        body.dark-theme .translate-options,
        body.dark-theme .ms-panel,
        body.dark-theme #search-results-container,
        body.dark-theme #options-search-results {
            background: linear-gradient(180deg, #0f172a 0%, #111c31 100%) !important;
            color: #e5eefc !important;
            border-color: rgba(148, 163, 184, 0.22) !important;
            box-shadow: 0 14px 34px rgba(2, 6, 23, 0.32) !important;
        }

        body.dark-theme #setup-search-row,
        body.dark-theme .options-search-box {
            background: transparent !important;
            border-color: transparent !important;
            box-shadow: none !important;
        }

        body.dark-theme .options-search-input-wrap {
            border: 2.5px solid transparent !important;
            background:
                linear-gradient(180deg, #111827 0%, #0f172a 100%) padding-box,
                linear-gradient(135deg, rgba(96, 165, 250, 0.78) 0%, rgba(59, 130, 246, 0.7) 42%, rgba(129, 140, 248, 0.82) 100%) border-box !important;
            box-shadow:
                inset 0 1px 0 rgba(255, 255, 255, 0.03),
                0 0 0 1px rgba(96, 165, 250, 0.18),
                0 16px 30px rgba(2, 6, 23, 0.26),
                0 0 28px rgba(59, 130, 246, 0.14) !important;
        }

        body.dark-theme .options-search-input-wrap:focus-within {
            background:
                linear-gradient(180deg, #101827 0%, #0d1528 100%) padding-box,
                linear-gradient(135deg, rgba(125, 211, 252, 0.96) 0%, rgba(59, 130, 246, 0.92) 40%, rgba(99, 102, 241, 0.94) 100%) border-box !important;
            box-shadow:
                0 0 0 4px rgba(59, 130, 246, 0.14),
                0 18px 36px rgba(2, 6, 23, 0.32),
                0 0 34px rgba(59, 130, 246, 0.18) !important;
        }

        body.dark-theme .ms-btn,
        body.dark-theme .révision-filter-btn {
            background: #0f172a !important;
            color: #e5eefc !important;
            border-color: rgba(148, 163, 184, 0.22) !important;
            box-shadow: none !important;
        }

        body.dark-theme .ms-btn:hover,
        body.dark-theme .ms-btn.active,
        body.dark-theme .révision-filter-btn:hover,
        body.dark-theme .révision-filter-btn.active {
            background: #162033 !important;
            color: #dbe8ff !important;
            border-color: rgba(96, 165, 250, 0.32) !important;
        }

        body.dark-theme .ms-item,
        body.dark-theme .révision-filter-option,
        body.dark-theme .translate-option {
            color: #e5eefc !important;
        }

        body.dark-theme .ms-item:hover,
        body.dark-theme .ms-item.selected,
        body.dark-theme .révision-filter-option:hover,
        body.dark-theme .translate-option:hover {
            background: #162033 !important;
        }

        body.dark-theme #desktop-quick-search-input,
        body.dark-theme #options-lesson-search,
        body.dark-theme .q-count-input,
        body.dark-theme .question-comment-input {
            background: transparent !important;
            color: #e5eefc !important;
            border-color: rgba(148, 163, 184, 0.24) !important;
            box-shadow: none !important;
        }

        body.dark-theme #options-lesson-search:focus,
        body.dark-theme #desktop-quick-search-input:focus,
        body.dark-theme .question-comment-input:focus {
            background: transparent !important;
            border-color: rgba(129, 140, 248, 0.65) !important;
        }

        body.dark-theme #question-card,
        body.dark-theme #question-card-study {
            background: linear-gradient(180deg, #0f172a 0%, #111827 100%) !important;
            color: #e5eefc !important;
            border: 1px solid rgba(148, 163, 184, 0.22) !important;
            box-shadow: 0 18px 36px rgba(2, 6, 23, 0.34) !important;
        }

        body.dark-theme .year-section,
        body.dark-theme .module-card,
        body.dark-theme .lesson-item,
        body.dark-theme .stat-item {
            background: #111827 !important;
            color: #e5eefc !important;
            border-color: rgba(148, 163, 184, 0.16) !important;
            box-shadow: 0 10px 28px rgba(2, 6, 23, 0.26) !important;
        }

        body.dark-theme .year-section:hover,
        body.dark-theme .module-card:hover,
        body.dark-theme .lesson-item:hover,
        body.dark-theme .option-search-item:hover,
        body.dark-theme .filter-option-item:hover,
        body.dark-theme .filter-option-item.selected {
            background: #162033 !important;
            box-shadow: 0 14px 30px rgba(2, 6, 23, 0.32) !important;
        }

        body.dark-theme .year-title,
        body.dark-theme .module-name,
        body.dark-theme .lesson-name,
        body.dark-theme .lesson-question-count,
        body.dark-theme .qcm-catalog-loader-status,
        body.dark-theme .qcm-catalog-loader-detail,
        body.dark-theme .qcm-catalog-loader-title,
        body.dark-theme .question-comment-title,
        body.dark-theme .question-comment-subtitle,
        body.dark-theme .question-comment-action-hint,
        body.dark-theme .stat-label,
        body.dark-theme .stat-value,
        body.dark-theme .option-search-item,
        body.dark-theme .option-search-meta,
        body.dark-theme #question-text,
        body.dark-theme .opt-text,
        body.dark-theme .question-comment-item-text,
        body.dark-theme .question-comment-item-date,
        body.dark-theme .question-comment-item-badge,
        body.dark-theme .question-comment-count {
            color: #e5eefc !important;
        }

        body.dark-theme .count-badge,
        body.dark-theme .question-day-chip.empty,
        body.dark-theme .filter-option-item,
        body.dark-theme .question-comment-item,
        body.dark-theme .question-comment-audio-btn,
        body.dark-theme .question-comment-voice-btn,
        body.dark-theme .question-comment-save-btn,
        body.dark-theme .question-comment-cancel-btn,
        body.dark-theme .question-comment-item-btn {
            background: #162033 !important;
            color: #dbe8ff !important;
            border-color: rgba(148, 163, 184, 0.18) !important;
        }

        body.dark-theme .question-comment-audio-btn {
            background: linear-gradient(135deg, rgba(146, 64, 14, 0.3) 0%, rgba(120, 53, 15, 0.28) 100%) !important;
            color: #fde68a !important;
            border-color: rgba(251, 191, 36, 0.34) !important;
        }

        body.dark-theme .question-comment-audio-btn.is-recording {
            background: linear-gradient(135deg, rgba(159, 18, 57, 0.36) 0%, rgba(136, 19, 55, 0.3) 100%) !important;
            color: #fecdd3 !important;
            border-color: rgba(251, 113, 133, 0.38) !important;
        }

        body.dark-theme .question-comment-audio-btn:disabled {
            opacity: 0.5;
            box-shadow: none !important;
        }

        body.dark-theme .question-comment-voice-btn {
            background: linear-gradient(135deg, rgba(13, 148, 136, 0.26) 0%, rgba(15, 118, 110, 0.22) 100%) !important;
            color: #99f6e4 !important;
            border-color: rgba(45, 212, 191, 0.34) !important;
        }

        body.dark-theme .question-comment-voice-btn.is-recording {
            background: linear-gradient(135deg, rgba(159, 18, 57, 0.36) 0%, rgba(136, 19, 55, 0.3) 100%) !important;
            color: #fecdd3 !important;
            border-color: rgba(251, 113, 133, 0.38) !important;
        }

        body.dark-theme .question-comment-voice-btn:disabled {
            opacity: 0.5;
            box-shadow: none !important;
        }

        body.dark-theme .question-comment-item-audio {
            background: linear-gradient(180deg, rgba(15, 23, 42, 0.88) 0%, rgba(17, 24, 39, 0.92) 100%) !important;
            border-color: rgba(148, 163, 184, 0.28) !important;
        }

        body.dark-theme .question-comment-count {
            background: rgba(22, 32, 51, 0.96) !important;
            border-color: rgba(96, 165, 250, 0.26) !important;
            box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03) !important;
        }

        body.dark-theme .question-comment-count.is-limit {
            background: rgba(120, 53, 15, 0.34) !important;
            border-color: rgba(251, 191, 36, 0.34) !important;
            color: #fde68a !important;
        }

        body.dark-theme .question-comment-empty {
            background: #162033 !important;
            border-color: rgba(148, 163, 184, 0.22) !important;
            color: #dbe8ff !important;
        }

        body.dark-theme .qcm-catalog-loader::before {
            background: linear-gradient(110deg, transparent 0%, rgba(148, 163, 184, 0.12) 40%, transparent 72%) !important;
        }

        body.dark-theme .qcm-catalog-loader-badge {
            background: rgba(14, 165, 233, 0.16) !important;
            color: #7dd3fc !important;
        }

        body.dark-theme .qcm-catalog-loader.is-ready .qcm-catalog-loader-badge {
            background: rgba(34, 197, 94, 0.14) !important;
            color: #86efac !important;
        }

        body.dark-theme .qcm-catalog-loader-track {
            background: #1e293b !important;
        }

        body.dark-theme .qcm-catalog-loader-note {
            color: #5eead4 !important;
        }

        body.dark-theme .count-badge {
            box-shadow: none !important;
        }

        body.dark-theme .option-search-item,
        body.dark-theme .option-search-item:last-child,
        body.dark-theme #search-results-container > div,
        body.dark-theme #search-results-container div {
            border-color: rgba(148, 163, 184, 0.16) !important;
            color: #e5eefc !important;
        }

        body.dark-theme .question-stats {
            background: linear-gradient(180deg, #0f172a 0%, #111c31 100%) !important;
            border-color: rgba(148, 163, 184, 0.22) !important;
            box-shadow: 0 12px 30px rgba(2, 6, 23, 0.28) !important;
        }

        body.dark-theme .question-stats-pill.neutral {
            background: #162033 !important;
            border-color: rgba(148, 163, 184, 0.2) !important;
            color: #dbe8ff !important;
        }

        body.dark-theme .question-stats-pill.success {
            background: rgba(34, 197, 94, 0.14) !important;
            border-color: rgba(74, 222, 128, 0.35) !important;
            color: #86efac !important;
        }

        body.dark-theme .question-stats-pill.danger {
            background: rgba(239, 68, 68, 0.14) !important;
            border-color: rgba(248, 113, 113, 0.35) !important;
            color: #fca5a5 !important;
        }

        body.dark-theme .question-stats-pill.info {
            background: rgba(59, 130, 246, 0.15) !important;
            border-color: rgba(96, 165, 250, 0.34) !important;
            color: #93c5fd !important;
        }

        body.dark-theme .question-stats-days::-webkit-scrollbar-track {
            background: rgba(30, 41, 59, 0.88) !important;
        }

        body.dark-theme .question-stats-days::-webkit-scrollbar-thumb {
            background: rgba(100, 116, 139, 0.9) !important;
        }

        body.dark-theme .question-day-chip.correct-only {
            background: rgba(34, 197, 94, 0.14) !important;
            border-color: rgba(74, 222, 128, 0.35) !important;
            color: #86efac !important;
        }

        body.dark-theme .question-day-chip.wrong-only {
            background: rgba(239, 68, 68, 0.14) !important;
            border-color: rgba(248, 113, 113, 0.35) !important;
            color: #fca5a5 !important;
        }

        body.dark-theme .question-day-chip.mixed {
            background: rgba(245, 158, 11, 0.14) !important;
            border-color: rgba(251, 191, 36, 0.35) !important;
            color: #fcd34d !important;
        }

        body.dark-theme .opt-btn,
        body.dark-theme .inline-ai-btn,
        body.dark-theme .inline-next-btn,
        body.dark-theme .inline-verify-btn,
        body.dark-theme .inline-todo-btn {
            background: #111827 !important;
            border-color: rgba(148, 163, 184, 0.2) !important;
            box-shadow: none !important;
        }

        body.dark-theme .opt-id {
            background: #1f2937 !important;
            color: #cbd5e1 !important;
        }

        body.dark-theme .opt-btn.multi-selected {
            background: linear-gradient(135deg, rgba(59, 130, 246, 0.22) 0%, rgba(37, 99, 235, 0.22) 100%) !important;
            border-color: rgba(96, 165, 250, 0.72) !important;
        }

        body.dark-theme .opt-btn.multi-selected .opt-id {
            background: rgba(30, 64, 175, 0.42) !important;
            color: #bfdbfe !important;
            border: 1px solid rgba(96, 165, 250, 0.36) !important;
        }

        body.dark-theme .opt-btn.multi-selected .opt-text {
            color: #dbeafe !important;
        }

        body.dark-theme .opt-btn.correct {
            background: linear-gradient(135deg, rgba(16, 185, 129, 0.24) 0%, rgba(5, 150, 105, 0.24) 100%) !important;
            border-color: rgba(52, 211, 153, 0.7) !important;
        }

        body.dark-theme .opt-btn.correct .opt-id {
            background: rgba(6, 95, 70, 0.48) !important;
            color: #bbf7d0 !important;
            border: 1px solid rgba(74, 222, 128, 0.34) !important;
        }

        body.dark-theme .opt-btn.correct .opt-text {
            color: #d1fae5 !important;
        }

        body.dark-theme .opt-btn.wrong {
            background: linear-gradient(135deg, rgba(239, 68, 68, 0.24) 0%, rgba(220, 38, 38, 0.24) 100%) !important;
            border-color: rgba(248, 113, 113, 0.72) !important;
            color: #fecaca !important;
        }

        body.dark-theme .opt-btn.wrong .opt-id {
            background: rgba(127, 29, 29, 0.48) !important;
            color: #fecaca !important;
            border: 1px solid rgba(248, 113, 113, 0.34) !important;
        }

        body.dark-theme .opt-btn.missed {
            background: linear-gradient(135deg, rgba(245, 158, 11, 0.24) 0%, rgba(217, 119, 6, 0.24) 100%) !important;
            border-color: rgba(251, 191, 36, 0.72) !important;
        }

        body.dark-theme .opt-btn.missed .opt-id {
            background: rgba(120, 53, 15, 0.48) !important;
            color: #fde68a !important;
            border: 1px solid rgba(251, 191, 36, 0.34) !important;
        }

        body.dark-theme .opt-btn.missed .opt-text {
            color: #fef3c7 !important;
        }

        body.dark-theme .answer-item.selected,
        body.dark-theme .answer-item.correct,
        body.dark-theme .answer-item.wrong,
        body.dark-theme .answer-item.missed {
            box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04), 0 10px 24px rgba(2, 6, 23, 0.2) !important;
        }

        body.dark-theme .option-justification-btn {
            background: #162033 !important;
            color: #dbe8ff !important;
            border-color: rgba(148, 163, 184, 0.18) !important;
        }

        body.dark-theme .opt-delete-btn {
            background: rgba(127, 29, 29, 0.42) !important;
            border-color: rgba(248, 113, 113, 0.3) !important;
            color: #fca5a5 !important;
        }

        body.dark-theme .answer-inline-separator {
            color: #64748b !important;
        }

        body.dark-theme .answer-item.neutral {
            background: #111827 !important;
            color: #94a3b8 !important;
            border-color: rgba(148, 163, 184, 0.2) !important;
        }

        body.dark-theme #quiz-timers-row .mini-timer-pill,
        body.dark-theme #qcm-control-bar,
        body.dark-theme #qcm-control-main-row > button,
        body.dark-theme #qcm-main-translate-host .large-translate-btn,
        body.dark-theme #quality-rating-shell,
        body.dark-theme #difficulty-rating-shell,
        body.dark-theme #quiz-side-actions-row > button {
            background: #0f172a !important;
            border-color: rgba(148, 163, 184, 0.24) !important;
            box-shadow: 0 6px 18px rgba(2, 6, 23, 0.24) !important;
        }

        body.dark-theme #qcm-control-main-row {
            border-bottom-color: rgba(148, 163, 184, 0.18) !important;
        }

        body.dark-theme #qcm-control-extra-row > div[style*="width:1px"] {
            background: rgba(148, 163, 184, 0.22) !important;
        }

        body.dark-theme #quality-rating-shell > span,
        body.dark-theme #difficulty-rating-shell > span {
            color: #dbe8ff !important;
        }

        body.dark-theme #rating-quality .large-star,
        body.dark-theme #rating-difficulty .large-star {
            color: #64748b !important;
        }

        body.dark-theme #options-panel > button,
        body.dark-theme #options-panel > button span,
        body.dark-theme #options-panel > button i,
        body.dark-theme .stats-title {
            color: #dbe8ff !important;
            border-color: rgba(148, 163, 184, 0.18) !important;
        }

        body.dark-theme #quiz-panel.test-workspace #quiz-info-column > * + * {
            border-top-color: rgba(148, 163, 184, 0.16) !important;
        }

        body.dark-theme #quiz-panel.test-workspace {
            background: linear-gradient(180deg, rgba(8, 13, 24, 0.98) 0%, rgba(15, 23, 42, 0.98) 100%) !important;
            border: 1px solid rgba(148, 163, 184, 0.16);
            box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03), 0 20px 40px rgba(2, 6, 23, 0.32);
        }

        body.dark-theme #quiz-top-unified-card {
            background: linear-gradient(180deg, rgba(17, 24, 39, 0.98) 0%, rgba(15, 23, 42, 0.98) 100%) !important;
            border-color: rgba(148, 163, 184, 0.2) !important;
            box-shadow: 0 16px 34px rgba(2, 6, 23, 0.42), inset 0 1px 0 rgba(255, 255, 255, 0.04) !important;
        }

        body.dark-theme #quiz-top-unified-card > * + * {
            border-top-color: rgba(148, 163, 184, 0.16) !important;
        }

        body.dark-theme #quiz-panel.test-workspace #question-stats,
        body.dark-theme #quiz-panel.test-workspace #quiz-stats-section {
            background: linear-gradient(180deg, rgba(15, 23, 42, 0.94) 0%, rgba(17, 28, 49, 0.94) 100%) !important;
            border-color: rgba(148, 163, 184, 0.22) !important;
            box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03), 0 8px 20px rgba(2, 6, 23, 0.28) !important;
        }

        body.dark-theme #quiz-panel.test-workspace #question-stats .révision-date {
            background: rgba(148, 163, 184, 0.14) !important;
            color: #dbe8ff !important;
        }

        body.dark-theme #quiz-panel.test-workspace #qcm-control-extra-row > div:not([style*="width:1px"]),
        body.dark-theme #quiz-panel.test-workspace #quality-rating-shell,
        body.dark-theme #quiz-panel.test-workspace #difficulty-rating-shell,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #quality-rating-shell,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #difficulty-rating-shell {
            background: #0f172a !important;
            border-color: rgba(148, 163, 184, 0.24) !important;
            box-shadow: 0 6px 18px rgba(2, 6, 23, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.03) !important;
        }

        body.dark-theme #quiz-panel.test-workspace #quality-rating-shell > span,
        body.dark-theme #quiz-panel.test-workspace #difficulty-rating-shell > span,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #quality-rating-shell > span,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #difficulty-rating-shell > span {
            background: rgba(22, 32, 51, 0.98) !important;
            color: #dbe8ff !important;
            border: 1px solid rgba(96, 165, 250, 0.24) !important;
        }

        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-quality .large-star,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-difficulty .large-star {
            background: #162033 !important;
            border-color: rgba(71, 85, 105, 0.82) !important;
            color: #64748b !important;
        }

        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row .mini-timer-pill span:first-of-type {
            color: #cbd5e1 !important;
        }

        body.dark-theme #quiz-panel.test-workspace #question-total-timer {
            color: #93c5fd !important;
        }

        body.dark-theme #quiz-panel.test-workspace #question-q-timer {
            color: #6ee7b7 !important;
        }

        body.dark-theme #quiz-panel.test-workspace #qcm-control-extra-row .large-star.active,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-quality .large-star.active,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-difficulty .large-star.active,
        body.dark-theme #quiz-panel.test-workspace #qcm-control-extra-row .large-star:active,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-quality .large-star:active,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-difficulty .large-star:active {
            background: rgba(245, 158, 11, 0.14) !important;
            border-color: rgba(251, 191, 36, 0.34) !important;
            color: #fbbf24 !important;
        }

        body.dark-theme #sidebar-nav.test-workspace-sidebar,
        body.dark-theme #sidebar-nav.test-workspace-sidebar #nav-items-container {
            scrollbar-color: rgba(148, 163, 184, 0.92) rgba(15, 23, 42, 0.38) !important;
        }

        body.dark-theme #sidebar-nav.test-workspace-sidebar::-webkit-scrollbar,
        body.dark-theme #sidebar-nav.test-workspace-sidebar #nav-items-container::-webkit-scrollbar {
            width: 4px;
        }

        body.dark-theme #sidebar-nav.test-workspace-sidebar::-webkit-scrollbar-track,
        body.dark-theme #sidebar-nav.test-workspace-sidebar #nav-items-container::-webkit-scrollbar-track {
            background: rgba(30, 41, 59, 0.36);
            border-radius: 999px;
        }

        body.dark-theme #sidebar-nav.test-workspace-sidebar::-webkit-scrollbar-thumb,
        body.dark-theme #sidebar-nav.test-workspace-sidebar #nav-items-container::-webkit-scrollbar-thumb {
            background: linear-gradient(180deg, rgba(148, 163, 184, 0.95) 0%, rgba(100, 116, 139, 0.95) 100%);
            border-radius: 999px;
        }

        body.dark-theme #setup-section.test-workspace-active {
            scrollbar-color: rgba(148, 163, 184, 0.92) rgba(15, 23, 42, 0.38);
        }

        body.dark-theme #setup-section.test-workspace-active::-webkit-scrollbar {
            width: 4px;
        }

        body.dark-theme #setup-section.test-workspace-active::-webkit-scrollbar-track {
            background: rgba(30, 41, 59, 0.36);
        }

        body.dark-theme #setup-section.test-workspace-active::-webkit-scrollbar-thumb {
            background: linear-gradient(180deg, rgba(148, 163, 184, 0.95) 0%, rgba(100, 116, 139, 0.95) 100%);
            border-radius: 999px;
        }

        body.dark-theme .app-top-banner-mobile-btn,
        body.dark-theme .mobile-sidebar-close-btn {
            background: rgba(15, 23, 42, 0.9);
            color: #e5eefc;
            border-color: rgba(148, 163, 184, 0.22);
        }

        body.dark-theme .mobile-sidebar-bottom-nav {
            background: rgba(15, 23, 42, 0.94);
            border-color: rgba(71, 85, 105, 0.72);
            box-shadow: 0 22px 38px rgba(2, 6, 23, 0.46);
        }

        body.dark-theme .mobile-sidebar-bottom-btn {
            color: #cbd5e1;
        }

        body.dark-theme .mobile-sidebar-bottom-btn:hover,
        body.dark-theme .mobile-sidebar-bottom-btn:active {
            background: rgba(37, 99, 235, 0.16);
            color: #dbeafe;
        }

        body.dark-theme .mobile-sidebar-bottom-btn.is-menu,
        body.dark-theme .mobile-sidebar-bottom-btn.is-home {
            background: transparent;
            color: #cbd5e1;
        }

        body.dark-theme #quiz-panel.test-workspace #qcm-control-extra-row,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row {
            background: transparent !important;
        }

        body.dark-theme #quiz-panel.test-workspace #qcm-control-extra-row > div[style*="width:1px"] {
            background: rgba(71, 85, 105, 0.92) !important;
        }

        body.dark-theme #quiz-panel.test-workspace #quality-rating-shell,
        body.dark-theme #quiz-panel.test-workspace #difficulty-rating-shell,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #quality-rating-shell,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #difficulty-rating-shell {
            background: linear-gradient(180deg, #0f172a 0%, #111c31 100%) !important;
            background-image: none !important;
            border-color: rgba(71, 85, 105, 0.76) !important;
            box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03), 0 10px 22px rgba(2, 6, 23, 0.28) !important;
            overflow: hidden !important;
        }

        body.dark-theme #quiz-panel.test-workspace #rating-quality,
        body.dark-theme #quiz-panel.test-workspace #rating-difficulty,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-quality,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-difficulty {
            background: transparent !important;
        }

        body.dark-theme #quiz-panel.test-workspace #rating-quality .large-star,
        body.dark-theme #quiz-panel.test-workspace #rating-difficulty .large-star,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-quality .large-star,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-difficulty .large-star {
            background: transparent !important;
            border-color: transparent !important;
            box-shadow: none !important;
        }

        body.dark-theme #btn-prev-main,
        body.dark-theme #btn-next-main,
        body.dark-theme .btn-prev-main,
        body.dark-theme .btn-next-main {
            color: #ffffff !important;
            background: #0f172a !important;
            border-color: rgba(148, 163, 184, 0.34) !important;
        }

        body.dark-theme #btn-prev-main i,
        body.dark-theme #btn-next-main i,
        body.dark-theme .btn-prev-main i,
        body.dark-theme .btn-next-main i {
            color: #ffffff !important;
        }

        body.dark-theme #btn-prev-main:hover,
        body.dark-theme #btn-next-main:hover,
        body.dark-theme .btn-prev-main:hover,
        body.dark-theme .btn-next-main:hover {
            background: #162033 !important;
            border-color: rgba(96, 165, 250, 0.34) !important;
        }

        #quiz-panel.test-workspace #quiz-timers-row #rating-quality,
        #quiz-panel.test-workspace #quiz-timers-row #rating-difficulty,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-quality,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-difficulty {
            display: flex !important;
            align-items: center !important;
            justify-content: flex-end !important;
            gap: 2px !important;
            max-width: min(100%, 58px) !important;
            overflow: visible !important;
        }

        #quiz-panel.test-workspace #quiz-timers-row #rating-quality .large-star,
        #quiz-panel.test-workspace #quiz-timers-row #rating-difficulty .large-star,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-quality .large-star,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-difficulty .large-star {
            width: auto !important;
            min-width: 0 !important;
            height: auto !important;
            aspect-ratio: auto !important;
            padding: 0 !important;
            border: none !important;
            border-radius: 0 !important;
            background: transparent !important;
            box-shadow: none !important;
            overflow: visible !important;
            font-family: "Segoe UI Symbol", "Noto Sans Symbols", sans-serif !important;
            font-size: 8px !important;
            line-height: 1 !important;
            text-shadow: none !important;
            -webkit-text-stroke: 0 !important;
            transform: none !important;
        }

        #quiz-panel.test-workspace #quiz-timers-row #rating-quality .large-star.active,
        #quiz-panel.test-workspace #quiz-timers-row #rating-difficulty .large-star.active,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-quality .large-star.active,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #rating-difficulty .large-star.active {
            background: transparent !important;
            border-color: transparent !important;
            box-shadow: none !important;
        }

        body.dark-theme #todo-list-block,
        body.dark-theme #srs-block {
            background: #07101c !important;
            color: #e5eefc !important;
        }

        body.dark-theme #todo-list-block {
            background: linear-gradient(180deg, #0b1324 0%, #111827 100%) !important;
        }

        body.dark-theme .todo-list-header {
            background: linear-gradient(135deg, #0f172a 0%, #162033 100%) !important;
            box-shadow: 0 12px 28px rgba(2, 6, 23, 0.34) !important;
        }

        body.dark-theme .todo-list-count,
        body.dark-theme .todo-list-close {
            background: rgba(22, 32, 51, 0.94) !important;
            border-color: rgba(148, 163, 184, 0.22) !important;
            color: #e5eefc !important;
        }

        body.dark-theme .todo-list-toolbar {
            background: linear-gradient(180deg, #0f172a 0%, #111c31 100%) !important;
            border-bottom-color: rgba(148, 163, 184, 0.18) !important;
        }

        body.dark-theme .todo-filter-select,
        body.dark-theme .todo-list-item,
        body.dark-theme .todo-list-item.is-done,
        body.dark-theme .todo-list-chip,
        body.dark-theme .todo-list-test-btn {
            background: #111c31 !important;
            color: #e5eefc !important;
            border-color: rgba(148, 163, 184, 0.22) !important;
            box-shadow: none !important;
        }

        body.dark-theme .todo-list-item {
            background: linear-gradient(180deg, #0f172a 0%, #111c31 100%) !important;
            box-shadow: 0 12px 24px rgba(2, 6, 23, 0.24) !important;
        }

        body.dark-theme .todo-list-item.is-done {
            background: linear-gradient(180deg, #111827 0%, #1a2437 100%) !important;
        }

        body.dark-theme .todo-list-title,
        body.dark-theme .todo-list-empty,
        body.dark-theme .todo-list-empty i {
            color: #e5eefc !important;
        }

        body.dark-theme .todo-list-item.is-done .todo-list-title {
            color: #94a3b8 !important;
        }

        body.dark-theme .todo-list-chip {
            color: #dbe8ff !important;
        }

        body.dark-theme .todo-list-test-btn {
            background: rgba(37, 99, 235, 0.14) !important;
            color: #bfdbfe !important;
            border-color: rgba(96, 165, 250, 0.28) !important;
        }

        body.dark-theme .todo-list-empty i {
            opacity: 0.7;
        }

        body.dark-theme #srs-block > div:first-child {
            background: linear-gradient(135deg, #0f172a 0%, #162033 100%) !important;
            box-shadow: 0 10px 26px rgba(2, 6, 23, 0.34) !important;
        }

        body.dark-theme #srs-block > div:first-child div[style*="background:rgba(255,255,255,0.15)"],
        body.dark-theme #srs-block > div:first-child div[style*="background:rgba(255,255,255,0.16)"],
        body.dark-theme #srs-block > div:first-child button[style*="background:rgba(255,255,255,0.15)"],
        body.dark-theme #srs-block > div:first-child button[style*="background:rgba(255,255,255,0.18)"],
        body.dark-theme #srs-block > div:first-child button[style*="background:rgba(254,226,226,0.25)"] {
            background: rgba(22, 32, 51, 0.94) !important;
            border-color: rgba(148, 163, 184, 0.22) !important;
            color: #e5eefc !important;
        }

        body.dark-theme #srs-block > div:nth-child(2) {
            background: linear-gradient(180deg, #0b1324 0%, #111827 100%) !important;
        }

        body.dark-theme #srs-block > div:nth-child(2) > div:first-child {
            background: linear-gradient(180deg, #0f172a 0%, #111c31 100%) !important;
            border-color: rgba(148, 163, 184, 0.22) !important;
            box-shadow: 0 16px 30px rgba(2, 6, 23, 0.3) !important;
        }

        body.dark-theme #srs-block > div:nth-child(2) > div:first-child > div:first-child {
            background: linear-gradient(180deg, #111827 0%, #162033 100%) !important;
            border-bottom-color: rgba(148, 163, 184, 0.18) !important;
        }

        body.dark-theme #srs-block > div:nth-child(2) > div:first-child > div:nth-child(2) {
            background: #111827 !important;
            border-bottom-color: rgba(148, 163, 184, 0.18) !important;
            color: #cbd5e1 !important;
        }

        body.dark-theme #srs-block #srs-list-container,
        body.dark-theme #srs-block #srs-list-count,
        body.dark-theme #srs-block .srs-filters-grid,
        body.dark-theme #srs-block .srs-filter-select {
            color: #e5eefc !important;
        }

        body.dark-theme #srs-block .srs-filter-select,
        body.dark-theme #srs-block #srs-filter-day {
            background: #0b1324 !important;
            border-color: rgba(148, 163, 184, 0.24) !important;
            color: #e5eefc !important;
            box-shadow: none !important;
        }

        body.dark-theme .simulation-inline-controls-grid .simulation-field-label,
        body.dark-theme .simulation-module-controls-grid .simulation-field-label,
        body.dark-theme .simulation-title-actions-row .simulation-field-label {
            color: #9ab0cf !important;
        }

        body.dark-theme #simulation-builder-panel .simulation-field-label {
            color: #000000 !important;
        }

        body.dark-theme .simulation-inline-controls-grid .simulation-field-select,
        body.dark-theme .simulation-inline-controls-grid .simulation-field-input,
        body.dark-theme .simulation-module-controls-grid .simulation-field-select,
        body.dark-theme .simulation-module-controls-grid .simulation-field-input,
        body.dark-theme .simulation-table-filters .simulation-field-select,
        body.dark-theme .simulation-title-count-field .simulation-field-input,
        body.dark-theme .simulation-inline-controls-grid .simulation-toggle-item,
        body.dark-theme .simulation-compact-picker .simulation-module-btn,
        body.dark-theme .todo-filter-select,
        body.dark-theme #srs-block .srs-filter-select {
            background: linear-gradient(180deg, #122033 0%, #16263d 100%) !important;
            border-color: rgba(120, 149, 194, 0.34) !important;
            color: #e6f0ff !important;
            box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03), 0 6px 14px rgba(2, 6, 23, 0.18) !important;
        }

        body.dark-theme .simulation-inline-controls-grid .simulation-toggle-item span,
        body.dark-theme .simulation-compact-picker .simulation-module-btn-label {
            color: #e6f0ff !important;
        }

        body.dark-theme .simulation-compact-picker .simulation-module-panel {
            background: linear-gradient(180deg, #101a2d 0%, #142239 100%) !important;
            border-color: rgba(120, 149, 194, 0.3) !important;
            box-shadow: 0 14px 28px rgba(2, 6, 23, 0.24) !important;
        }

        body.dark-theme .simulation-compact-picker .simulation-module-select-all,
        body.dark-theme .simulation-compact-picker .simulation-module-option {
            color: #e6f0ff !important;
        }

        body.dark-theme .simulation-compact-picker .simulation-module-select-all {
            background: linear-gradient(180deg, #16263d 0%, #1a2d48 100%) !important;
            border-color: rgba(120, 149, 194, 0.34) !important;
        }

        body.dark-theme .simulation-compact-picker .simulation-module-option {
            background: rgba(18, 32, 51, 0.88) !important;
        }

        body.dark-theme .simulation-compact-picker .simulation-module-btn-meta {
            color: #9ab0cf !important;
        }

        /* Unified filter polish */
        #years-ms,
        #rotations-ms,
        #faculty-ms,
        #languages-ms {
            --setup-filter-accent: #1d4ed8;
            --setup-filter-btn-bg: linear-gradient(180deg, #ffffff 0%, #eef5ff 100%);
            --setup-filter-panel-bg: linear-gradient(180deg, #ffffff 0%, #f3f8ff 100%);
            --setup-filter-option-bg: rgba(219, 234, 254, 0.76);
            --setup-filter-option-hover-bg: linear-gradient(180deg, #dbeafe 0%, #bfdbfe 100%);
            --setup-filter-option-active-bg: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
            --setup-filter-option-active-text: #ffffff;
            --setup-filter-border: #bfdbfe;
            --setup-filter-shadow: rgba(59, 130, 246, 0.18);
        }

        #years-ms {
            --setup-filter-accent: #047857;
            --setup-filter-btn-bg: linear-gradient(180deg, #f7fffb 0%, #e2fbe9 100%);
            --setup-filter-panel-bg: linear-gradient(180deg, #ffffff 0%, #f0fdf4 100%);
            --setup-filter-option-bg: rgba(209, 250, 229, 0.78);
            --setup-filter-option-hover-bg: linear-gradient(180deg, #d1fae5 0%, #a7f3d0 100%);
            --setup-filter-option-active-bg: linear-gradient(135deg, #10b981 0%, #047857 100%);
            --setup-filter-border: #a7f3d0;
            --setup-filter-shadow: rgba(16, 185, 129, 0.2);
        }

        #rotations-ms {
            --setup-filter-accent: #b45309;
            --setup-filter-btn-bg: linear-gradient(180deg, #fffdf7 0%, #fff4d6 100%);
            --setup-filter-panel-bg: linear-gradient(180deg, #ffffff 0%, #fff8eb 100%);
            --setup-filter-option-bg: rgba(254, 243, 199, 0.8);
            --setup-filter-option-hover-bg: linear-gradient(180deg, #fde68a 0%, #fcd34d 100%);
            --setup-filter-option-active-bg: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
            --setup-filter-border: #fcd34d;
            --setup-filter-shadow: rgba(245, 158, 11, 0.2);
        }

        #faculty-ms {
            --setup-filter-accent: #7c3aed;
            --setup-filter-btn-bg: linear-gradient(180deg, #fcf8ff 0%, #f1e7ff 100%);
            --setup-filter-panel-bg: linear-gradient(180deg, #ffffff 0%, #f7f0ff 100%);
            --setup-filter-option-bg: rgba(233, 213, 255, 0.78);
            --setup-filter-option-hover-bg: linear-gradient(180deg, #eadcff 0%, #d8b4fe 100%);
            --setup-filter-option-active-bg: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
            --setup-filter-border: #d8b4fe;
            --setup-filter-shadow: rgba(139, 92, 246, 0.2);
        }

        #languages-ms {
            --setup-filter-accent: #1d4ed8;
            --setup-filter-btn-bg: linear-gradient(180deg, #f8fbff 0%, #e8f1ff 100%);
            --setup-filter-panel-bg: linear-gradient(180deg, #ffffff 0%, #edf5ff 100%);
            --setup-filter-option-bg: rgba(219, 234, 254, 0.8);
            --setup-filter-option-hover-bg: linear-gradient(180deg, #dbeafe 0%, #bfdbfe 100%);
            --setup-filter-option-active-bg: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
            --setup-filter-border: #bfd8ff;
            --setup-filter-shadow: rgba(59, 130, 246, 0.2);
        }

        .multi-select .ms-btn {
            min-height: 36px !important;
            height: auto !important;
            padding: 9px 12px !important;
            border-radius: 16px !important;
            border: 1px solid var(--setup-filter-border) !important;
            background: var(--setup-filter-btn-bg) !important;
            color: var(--setup-filter-accent) !important;
            justify-content: flex-start !important;
            gap: 0 !important;
            box-shadow: 0 10px 24px var(--setup-filter-shadow) !important;
        }

        .multi-select .ms-btn:hover,
        .multi-select .ms-btn.active {
            background: var(--setup-filter-btn-bg) !important;
            color: var(--setup-filter-accent) !important;
            border-color: var(--setup-filter-border) !important;
            box-shadow: 0 12px 28px var(--setup-filter-shadow) !important;
            transform: none !important;
        }

        .multi-select .ms-btn i,
        .révision-filter-btn i,
        .simulation-module-btn-icon {
            display: none !important;
        }

        .révision-filter-select,
        .révision-filter-group select,
        .filter-select,
        .todo-filter-select,
        #srs-block .srs-filter-select,
        .simulation-inline-controls-grid .simulation-field-select,
        .simulation-module-controls-grid .simulation-field-select,
        .simulation-table-filters .simulation-field-select {
            appearance: none !important;
            -webkit-appearance: none !important;
            -moz-appearance: none !important;
            background-image: none !important;
            padding-right: 12px !important;
        }

        .révision-filter-select::-ms-expand,
        .révision-filter-group select::-ms-expand,
        .filter-select::-ms-expand,
        .todo-filter-select::-ms-expand,
        #srs-block .srs-filter-select::-ms-expand,
        .simulation-inline-controls-grid .simulation-field-select::-ms-expand,
        .simulation-module-controls-grid .simulation-field-select::-ms-expand,
        .simulation-table-filters .simulation-field-select::-ms-expand {
            display: none;
        }

        .multi-select .ms-btn .ms-btn-label,
        .révision-filter-btn span,
        .simulation-module-btn-label {
            display: block;
            min-width: 0;
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;
            font-weight: 800;
        }

        .multi-select .ms-panel {
            min-width: 220px;
            max-width: min(280px, calc(100vw - 24px));
            padding: 10px !important;
            border-radius: 18px !important;
            border: 1px solid var(--setup-filter-border) !important;
            background: var(--setup-filter-panel-bg) !important;
            box-shadow: 0 18px 34px var(--setup-filter-shadow) !important;
        }

        .multi-select .ms-list {
            display: flex !important;
            flex-direction: column;
            gap: 8px;
            max-height: 260px !important;
            padding: 2px 0 !important;
        }

        .multi-select .ms-item,
        .révision-filter-option,
        .simulation-module-select-all,
        .simulation-module-option,
        .filter-option-item {
            position: relative;
        }

        .multi-select .ms-item {
            min-height: 42px !important;
            padding: 10px 14px 10px 40px !important;
            border-radius: 14px !important;
            border: 1px solid transparent;
            background: var(--setup-filter-option-bg) !important;
            color: var(--setup-filter-accent) !important;
            transform: none !important;
            box-shadow: none !important;
            gap: 0 !important;
        }

        .multi-select .ms-item:hover {
            background: var(--setup-filter-option-hover-bg) !important;
            border-color: transparent !important;
            transform: none !important;
        }

        .multi-select .ms-item.selected,
        .multi-select .ms-item:has(input:checked) {
            background: var(--setup-filter-option-active-bg) !important;
            color: var(--setup-filter-option-active-text) !important;
            box-shadow: 0 10px 22px var(--setup-filter-shadow) !important;
        }

        .multi-select .ms-item input[type="checkbox"],
        .révision-filter-option input[type="checkbox"],
        .simulation-module-option input[type="checkbox"],
        .simulation-module-select-all input[type="checkbox"] {
            position: absolute !important;
            width: 1px !important;
            height: 1px !important;
            opacity: 0 !important;
            pointer-events: none !important;
            margin: 0 !important;
        }

        .multi-select .ms-item::before,
        .révision-filter-option::before,
        .simulation-module-select-all::before,
        .simulation-module-option::before,
        .filter-option-item::before {
            content: '';
            position: absolute;
            top: 50%;
            left: 16px;
            width: 12px;
            height: 6px;
            border-left: 3px solid currentColor;
            border-bottom: 3px solid currentColor;
            transform: translateY(-58%) rotate(-45deg) scale(0);
            transform-origin: center;
            opacity: 0;
            transition: transform 0.18s ease, opacity 0.18s ease;
            pointer-events: none;
        }

        .multi-select .ms-item.selected::before,
        .multi-select .ms-item:has(input:checked)::before,
        .révision-filter-option:has(input:checked)::before,
        .simulation-module-select-all:has(input:checked)::before,
        .simulation-module-select-all:has(input:indeterminate)::before,
        .simulation-module-option.is-selected::before,
        .simulation-module-option:has(input:checked)::before,
        .filter-option-item.selected::before {
            opacity: 1;
            transform: translateY(-58%) rotate(-45deg) scale(1);
        }

        .multi-select .ms-item div {
            min-width: 0;
            font-size: 12px !important;
            line-height: 1.35 !important;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .filter-selection-panel {
            padding: 10px !important;
            border-radius: 16px !important;
            background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%) !important;
            border: 1px solid #dbe5f0 !important;
            box-shadow: 0 18px 36px rgba(15, 23, 42, 0.14) !important;
        }

        .filter-option-item {
            position: relative;
            align-items: flex-start;
            min-height: 42px;
            padding: 10px 12px 10px 32px !important;
            margin-bottom: 8px !important;
            border-radius: 14px !important;
            border: 1px solid transparent;
            background: rgba(241, 245, 249, 0.92) !important;
            color: #1e293b !important;
            font-size: 10px !important;
        }

        .filter-option-item span:first-child {
            display: block;
            flex: 1 1 auto;
            min-width: 0;
            overflow: visible;
            text-overflow: clip;
            white-space: normal;
            overflow-wrap: anywhere;
            word-break: break-word;
            line-height: 1.32;
        }

        .filter-option-item:hover {
            background: linear-gradient(135deg, #eef4ff 0%, #ddeafe 100%) !important;
            border-color: #bfdbfe;
        }

        .filter-option-item.selected {
            background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%) !important;
            color: #ffffff !important;
        }

        .filter-option-item span:last-child {
            align-self: flex-start;
            margin-top: 2px;
            font-size: 9px !important;
            color: #64748b !important;
        }

        .filter-option-item.selected span:last-child {
            color: rgba(255, 255, 255, 0.88) !important;
        }

        .révision-filter-container {
            --révision-filter-accent: #1d4ed8;
            --révision-filter-btn-bg: linear-gradient(180deg, #ffffff 0%, #eef5ff 100%);
            --révision-filter-panel-bg: linear-gradient(180deg, #ffffff 0%, #f5f9ff 100%);
            --révision-filter-option-bg: rgba(219, 234, 254, 0.8);
            --révision-filter-option-hover-bg: linear-gradient(180deg, #dbeafe 0%, #bfdbfe 100%);
            --révision-filter-option-active-bg: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
            --révision-filter-border: #bfd8ff;
            --révision-filter-shadow: rgba(59, 130, 246, 0.18);
        }

        .révision-filter-btn {
            min-height: 40px;
            padding: 10px 14px !important;
            border-radius: 16px !important;
            border: 1px solid var(--révision-filter-border) !important;
            background: var(--révision-filter-btn-bg) !important;
            color: var(--révision-filter-accent) !important;
            box-shadow: 0 10px 24px var(--révision-filter-shadow) !important;
            gap: 0 !important;
        }

        .révision-filter-btn:hover,
        .révision-filter-btn.active {
            background: var(--révision-filter-btn-bg) !important;
            color: var(--révision-filter-accent) !important;
            border-color: var(--révision-filter-border) !important;
        }

        .révision-filter-dropdown {
            padding: 10px !important;
            border-radius: 18px !important;
            border: 1px solid var(--révision-filter-border) !important;
            background: var(--révision-filter-panel-bg) !important;
            box-shadow: 0 18px 34px var(--révision-filter-shadow) !important;
        }

        .révision-filter-option {
            min-height: 42px;
            padding: 10px 14px 10px 40px !important;
            border-radius: 14px !important;
            border: 1px solid transparent;
            background: var(--révision-filter-option-bg) !important;
            color: var(--révision-filter-accent) !important;
            gap: 0 !important;
        }

        .révision-filter-option:hover {
            background: var(--révision-filter-option-hover-bg) !important;
        }

        .révision-filter-option:has(input:checked) {
            background: var(--révision-filter-option-active-bg) !important;
            color: #ffffff !important;
            box-shadow: 0 10px 22px var(--révision-filter-shadow) !important;
        }

        .révision-filter-option span {
            color: inherit !important;
            font-size: 13px !important;
            font-weight: 700 !important;
        }

        .simulation-module-picker,
        .simulation-compact-picker {
            --simulation-filter-accent: #1d4ed8;
            --simulation-filter-btn-bg: linear-gradient(180deg, #ffffff 0%, #eef5ff 100%);
            --simulation-filter-panel-bg: linear-gradient(180deg, #ffffff 0%, #f5f9ff 100%);
            --simulation-filter-option-bg: rgba(219, 234, 254, 0.8);
            --simulation-filter-option-hover-bg: linear-gradient(180deg, #dbeafe 0%, #bfdbfe 100%);
            --simulation-filter-option-active-bg: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
            --simulation-filter-border: #bfd8ff;
            --simulation-filter-shadow: rgba(59, 130, 246, 0.18);
        }

        .simulation-module-btn {
            border-color: var(--simulation-filter-border) !important;
            background: var(--simulation-filter-btn-bg) !important;
            color: var(--simulation-filter-accent) !important;
            box-shadow: 0 10px 24px var(--simulation-filter-shadow) !important;
        }

        .simulation-module-btn:hover,
        .simulation-module-picker.is-open .simulation-module-btn {
            border-color: var(--simulation-filter-border) !important;
            box-shadow: 0 12px 28px var(--simulation-filter-shadow) !important;
        }

        .simulation-module-btn-copy {
            gap: 0 !important;
        }

        .simulation-module-btn-meta {
            display: none !important;
        }

        .simulation-module-panel {
            padding: 10px !important;
            border-radius: 18px !important;
            border: 1px solid var(--simulation-filter-border) !important;
            background: var(--simulation-filter-panel-bg) !important;
            box-shadow: 0 18px 34px var(--simulation-filter-shadow) !important;
        }

        .simulation-module-list {
            gap: 8px !important;
        }

        .simulation-module-select-all,
        .simulation-module-option {
            min-height: 42px !important;
            padding: 10px 14px 10px 40px !important;
            border-radius: 14px !important;
            border: 1px solid transparent !important;
            background: var(--simulation-filter-option-bg) !important;
            color: var(--simulation-filter-accent) !important;
            gap: 0 !important;
        }

        .simulation-module-select-all:hover,
        .simulation-module-option:hover {
            background: var(--simulation-filter-option-hover-bg) !important;
            border-color: transparent !important;
        }

        .simulation-module-select-all:has(input:checked),
        .simulation-module-option.is-selected,
        .simulation-module-option:has(input:checked) {
            background: var(--simulation-filter-option-active-bg) !important;
            color: #ffffff !important;
            box-shadow: 0 10px 22px var(--simulation-filter-shadow) !important;
        }

        body.dark-theme .filter-module {
            background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%) !important;
            color: #1e40af !important;
            border-color: #bfdbfe !important;
        }

        body.dark-theme .filter-lesson {
            background: linear-gradient(135deg, #e0e7ff 0%, #c7d2fe 100%) !important;
            color: #3730a3 !important;
            border-color: #c7d2fe !important;
        }

        body.dark-theme .filter-rotation {
            background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%) !important;
            color: #92400e !important;
            border-color: #fcd34d !important;
        }

        body.dark-theme .filter-year {
            background: linear-gradient(135deg, #dcfce7 0%, #bbf7d0 100%) !important;
            color: #166534 !important;
            border-color: #86efac !important;
        }

        body.dark-theme .filter-faculty {
            background: linear-gradient(135deg, #f3e8ff 0%, #e9d5ff 100%) !important;
            color: #6b21a8 !important;
            border-color: #d8b4fe !important;
        }

        body.dark-theme .filter-selection-panel {
            background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%) !important;
            color: #1e293b !important;
            border-color: #dbe5f0 !important;
            box-shadow: 0 18px 36px rgba(15, 23, 42, 0.14) !important;
        }

        body.dark-theme .filter-option-item {
            background: rgba(241, 245, 249, 0.92) !important;
            color: #1e293b !important;
            border-color: transparent !important;
            box-shadow: none !important;
        }

        body.dark-theme .filter-option-item:hover {
            background: linear-gradient(135deg, #eef4ff 0%, #ddeafe 100%) !important;
            border-color: #bfdbfe !important;
            box-shadow: none !important;
        }

        body.dark-theme .filter-option-item.selected {
            background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%) !important;
            color: #ffffff !important;
            box-shadow: 0 10px 22px rgba(59, 130, 246, 0.18) !important;
        }

        body.dark-theme .filter-option-item span:last-child {
            color: #64748b !important;
        }

        body.dark-theme .filter-option-item.selected span:last-child {
            color: rgba(255, 255, 255, 0.88) !important;
        }

        body.dark-theme .révision-filter-btn {
            background: var(--révision-filter-btn-bg) !important;
            color: var(--révision-filter-accent) !important;
            border-color: var(--révision-filter-border) !important;
            box-shadow: 0 10px 24px var(--révision-filter-shadow) !important;
        }

        body.dark-theme .révision-filter-dropdown {
            background: var(--révision-filter-panel-bg) !important;
            border-color: var(--révision-filter-border) !important;
            color: #0f172a !important;
            box-shadow: 0 18px 34px var(--révision-filter-shadow) !important;
        }

        body.dark-theme .révision-filter-option {
            background: var(--révision-filter-option-bg) !important;
            color: var(--révision-filter-accent) !important;
        }

        body.dark-theme .révision-filter-option:hover {
            background: var(--révision-filter-option-hover-bg) !important;
        }

        body.dark-theme .révision-filter-option:has(input:checked) {
            background: var(--révision-filter-option-active-bg) !important;
            color: #ffffff !important;
        }

        body.dark-theme .multi-select .ms-btn {
            background: var(--setup-filter-btn-bg) !important;
            color: var(--setup-filter-accent) !important;
            border-color: var(--setup-filter-border) !important;
            box-shadow: 0 10px 24px var(--setup-filter-shadow) !important;
        }

        body.dark-theme .multi-select .ms-panel {
            background: var(--setup-filter-panel-bg) !important;
            border-color: var(--setup-filter-border) !important;
            box-shadow: 0 18px 34px var(--setup-filter-shadow) !important;
        }

        body.dark-theme .multi-select .ms-item {
            background: var(--setup-filter-option-bg) !important;
            color: var(--setup-filter-accent) !important;
        }

        body.dark-theme .multi-select .ms-item:hover {
            background: var(--setup-filter-option-hover-bg) !important;
        }

        body.dark-theme .multi-select .ms-item.selected,
        body.dark-theme .multi-select .ms-item:has(input:checked) {
            background: var(--setup-filter-option-active-bg) !important;
            color: var(--setup-filter-option-active-text) !important;
        }

        body.dark-theme .simulation-module-btn,
        body.dark-theme .simulation-compact-picker .simulation-module-btn {
            background: var(--simulation-filter-btn-bg) !important;
            color: var(--simulation-filter-accent) !important;
            border-color: var(--simulation-filter-border) !important;
            box-shadow: 0 10px 24px var(--simulation-filter-shadow) !important;
        }

        body.dark-theme .simulation-module-btn-label,
        body.dark-theme .simulation-compact-picker .simulation-module-btn-label {
            color: var(--simulation-filter-accent) !important;
        }

        body.dark-theme .simulation-module-panel,
        body.dark-theme .simulation-compact-picker .simulation-module-panel {
            background: var(--simulation-filter-panel-bg) !important;
            border-color: var(--simulation-filter-border) !important;
            box-shadow: 0 18px 34px var(--simulation-filter-shadow) !important;
        }

        body.dark-theme .simulation-module-select-all,
        body.dark-theme .simulation-module-option,
        body.dark-theme .simulation-compact-picker .simulation-module-select-all,
        body.dark-theme .simulation-compact-picker .simulation-module-option {
            background: var(--simulation-filter-option-bg) !important;
            color: var(--simulation-filter-accent) !important;
            border-color: transparent !important;
        }

        body.dark-theme .simulation-module-select-all:hover,
        body.dark-theme .simulation-module-option:hover,
        body.dark-theme .simulation-compact-picker .simulation-module-select-all:hover,
        body.dark-theme .simulation-compact-picker .simulation-module-option:hover {
            background: var(--simulation-filter-option-hover-bg) !important;
        }

        body.dark-theme .simulation-module-select-all:has(input:checked),
        body.dark-theme .simulation-module-option.is-selected,
        body.dark-theme .simulation-module-option:has(input:checked),
        body.dark-theme .simulation-compact-picker .simulation-module-select-all:has(input:checked),
        body.dark-theme .simulation-compact-picker .simulation-module-option.is-selected,
        body.dark-theme .simulation-compact-picker .simulation-module-option:has(input:checked) {
            background: var(--simulation-filter-option-active-bg) !important;
            color: #ffffff !important;
        }

        body.dark-theme #simulation-builder-panel .simulation-inline-controls-grid .simulation-field[class*="simulation-filter-theme-"] .simulation-field-select,
        body.dark-theme #simulation-builder-panel .simulation-inline-controls-grid .simulation-field[class*="simulation-filter-theme-"] .simulation-field-input {
            background: var(--filter-pill-bg) !important;
            border-color: var(--filter-pill-border) !important;
            color: var(--filter-pill-text) !important;
            box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 6px 14px var(--builder-filter-shadow) !important;
        }

        body.dark-theme #simulation-builder-panel .simulation-inline-controls-grid .simulation-field[class*="simulation-filter-theme-"] .simulation-field-select {
            background-image:
                linear-gradient(45deg, transparent 50%, var(--filter-pill-arrow) 50%),
                linear-gradient(135deg, var(--filter-pill-arrow) 50%, transparent 50%),
                var(--filter-pill-bg) !important;
            background-position:
                calc(100% - 14px) calc(50% - 2px),
                calc(100% - 10px) calc(50% - 2px),
                0 0 !important;
            background-size: 6px 6px, 6px 6px, 100% 100% !important;
            background-repeat: no-repeat !important;
        }

        body.dark-theme #srs-settings-modal > div {
            background: #0f172a !important;
            border-color: rgba(148, 163, 184, 0.24) !important;
        }

        body.dark-theme #srs-settings-modal > div > div:first-child {
            background: linear-gradient(135deg, #0f172a 0%, #162033 100%) !important;
        }

        body.dark-theme #srs-settings-modal > div > div:nth-child(2),
        body.dark-theme #srs-settings-modal > div > div:nth-child(3) {
            background: #0f172a !important;
            color: #e5eefc !important;
            border-top-color: rgba(148, 163, 184, 0.18) !important;
        }

        body.dark-theme #srs-settings-modal label,
        body.dark-theme #srs-settings-modal > div > div:nth-child(2) > div:last-child {
            color: #e5eefc !important;
        }

        body.dark-theme #srs-settings-modal input,
        body.dark-theme #srs-settings-modal button[onclick="closeSrsSettingsModal()"] {
            background: #0b1324 !important;
            color: #e5eefc !important;
            border-color: rgba(148, 163, 184, 0.24) !important;
        }

        @media (max-width: 768px) {
            body:not(.intro-open) #main-content > .app-top-banner {
                display: none !important;
            }

            #left-sidebar.app-sidebar-shell.sidebar-collapsed {
                width: min(272px, calc(100vw - 32px)) !important;
                min-width: min(272px, calc(100vw - 32px)) !important;
            }

            #left-sidebar.app-sidebar-shell.sidebar-collapsed .app-sidebar-brand-copy,
            #left-sidebar.app-sidebar-shell.sidebar-collapsed .app-sidebar-profile,
            #left-sidebar.app-sidebar-shell.sidebar-collapsed .app-sidebar-link-text {
                display: block;
            }

            #left-sidebar.app-sidebar-shell.sidebar-collapsed .app-sidebar-top {
                flex-direction: row;
                margin-left: 14px;
                margin-right: 14px;
                padding-bottom: 12px;
                border-bottom: 1px solid #ebe9e6;
            }

            #left-sidebar.app-sidebar-shell.sidebar-collapsed .app-sidebar-controls {
                flex-direction: row;
            }

            #left-sidebar.app-sidebar-shell.sidebar-collapsed .app-sidebar-link {
                justify-content: flex-start;
                padding: 10px 12px;
            }

            #setup-section {
                padding-bottom: calc(92px + env(safe-area-inset-bottom, 0px));
            }

            .mobile-sidebar-bottom-nav {
                position: fixed;
                left: 10px;
                right: 10px;
                bottom: calc(10px + env(safe-area-inset-bottom, 0px));
                z-index: 2500;
                display: flex;
                align-items: center;
                justify-content: center;
                flex-wrap: nowrap;
                gap: 10px;
                padding: 8px 12px;
                border-radius: 22px;
                background: rgba(248, 250, 252, 0.94);
                border: 1px solid rgba(226, 232, 240, 0.94);
                box-shadow: 0 18px 34px rgba(15, 23, 42, 0.16);
                backdrop-filter: blur(14px);
                -webkit-backdrop-filter: blur(14px);
                overflow: hidden;
                transition: opacity 0.24s ease, transform 0.24s ease;
            }

            .mobile-sidebar-bottom-nav::-webkit-scrollbar {
                display: none;
            }

            body.mobile-sidebar-open .mobile-sidebar-bottom-nav,
            body.intro-open .mobile-sidebar-bottom-nav {
                opacity: 0;
                pointer-events: none;
                transform: translateY(18px);
            }

            .mobile-sidebar-bottom-btn {
                flex: 0 0 auto;
                display: inline-flex;
                align-items: center;
                justify-content: center;
                gap: 0;
                width: 58px;
                min-width: 58px;
                min-height: 46px;
                padding: 0;
                border-radius: 16px;
                color: #475569;
                font-size: 0;
                font-weight: 800;
                line-height: 1;
                text-align: center;
                white-space: nowrap;
                scroll-snap-align: start;
                transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease;
            }

            .mobile-sidebar-bottom-btn i {
                font-size: 1.04rem;
            }

            .mobile-sidebar-bottom-btn span {
                display: none;
            }

            .mobile-sidebar-bottom-btn:hover,
            .mobile-sidebar-bottom-btn:active {
                background: rgba(37, 99, 235, 0.1);
                color: #1d4ed8;
                transform: translateY(-1px);
            }

            .mobile-sidebar-bottom-btn.is-menu,
            .mobile-sidebar-bottom-btn.is-home {
                background: transparent;
                color: #475569;
            }

            body.qcm-workspace-active .mobile-test-next-btn {
                display: inline-flex;
            }
        }

        .test-summary-modal {
            position: fixed;
            inset: 0;
            z-index: 4000;
            display: none;
            align-items: center;
            justify-content: center;
            padding: 20px;
            background: rgba(15, 23, 42, 0.52);
            backdrop-filter: blur(10px);
        }

        .test-summary-modal.is-open {
            display: flex;
        }

        .test-summary-card {
            width: min(820px, 100%);
            max-height: min(92vh, 920px);
            overflow: auto;
            border-radius: 30px;
            padding: 28px;
            background: #ffffff;
            box-shadow: 0 30px 80px rgba(15, 23, 42, 0.28);
        }

        .test-summary-title {
            margin: 0 0 18px;
            text-align: center;
            font-size: clamp(1.5rem, 2.8vw, 2rem);
            font-weight: 900;
            color: #1f2937;
        }

        .test-summary-meta {
            display: grid;
            gap: 8px;
            margin-bottom: 22px;
            color: #334155;
            font-size: 1rem;
            font-weight: 700;
        }

        .test-summary-grid {
            display: grid;
            grid-template-columns: minmax(240px, 0.9fr) minmax(280px, 1fr);
            gap: 28px;
            align-items: center;
        }

        .test-summary-stats {
            display: grid;
            gap: 16px;
        }

        .test-summary-stat-box {
            border-radius: 22px;
            padding: 24px 18px;
            border: 1px solid rgba(109, 93, 252, 0.35);
            background: linear-gradient(180deg, #ffffff 0%, #f8f7ff 100%);
            text-align: center;
        }

        .test-summary-stat-label {
            color: #334155;
            font-size: 1.1rem;
            font-weight: 800;
        }

        .test-summary-stat-value {
            margin-top: 8px;
            color: #111827;
            font-size: 2rem;
            font-weight: 900;
        }

        .test-summary-breakdown {
            display: grid;
            justify-items: center;
            gap: 18px;
        }

        .test-summary-ring {
            width: 236px;
            height: 236px;
            border-radius: 50%;
            display: grid;
            place-items: center;
            background: conic-gradient(#22c55e 0 0%, #ef4444 0 0%, #6d5dfc 0 100%);
        }

        .test-summary-ring-inner {
            width: 145px;
            height: 145px;
            border-radius: 50%;
            display: grid;
            place-items: center;
            background: #ffffff;
            color: #1f2937;
            font-size: 1.3rem;
            font-weight: 900;
        }

        .test-summary-legend {
            width: min(320px, 100%);
            display: grid;
            gap: 10px;
        }

        .test-summary-legend-item {
            display: flex;
            align-items: center;
            gap: 10px;
            color: #475569;
            font-size: 0.98rem;
            font-weight: 700;
        }

        .test-summary-legend-item .dot {
            width: 10px;
            height: 10px;
            border-radius: 999px;
            flex: 0 0 auto;
        }

        .test-summary-legend-item .dot.is-good {
            background: #22c55e;
        }

        .test-summary-legend-item .dot.is-bad {
            background: #ef4444;
        }

        .test-summary-legend-item .dot.is-missed {
            background: #6d5dfc;
        }

        .test-summary-actions {
            display: grid;
            gap: 10px;
            margin-top: 24px;
        }

        .test-summary-primary,
        .test-summary-secondary,
        .test-summary-danger {
            width: 100%;
            min-height: 54px;
            border-radius: 16px;
            font-size: 1rem;
            font-weight: 900;
            transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
        }

        .test-summary-primary {
            border: none;
            color: #ffffff;
            background: linear-gradient(90deg, #6d5dfc 0%, #7c6bf8 100%);
            box-shadow: 0 18px 30px rgba(109, 93, 252, 0.24);
        }

        .test-summary-secondary {
            border: 1px solid rgba(109, 93, 252, 0.28);
            color: #6d5dfc;
            background: #ffffff;
        }

        .test-summary-danger {
            border: 1px solid rgba(239, 68, 68, 0.24);
            color: #ef4444;
            background: #ffffff;
        }

        .test-summary-primary:hover,
        .test-summary-secondary:hover,
        .test-summary-danger:hover {
            transform: translateY(-1px);
        }

        @media (max-width: 768px) {
            .test-summary-card {
                padding: 20px 16px;
                border-radius: 24px;
            }

            .test-summary-grid {
                grid-template-columns: 1fr;
                gap: 20px;
            }

            .test-summary-ring {
                width: 200px;
                height: 200px;
            }

            .test-summary-ring-inner {
                width: 122px;
                height: 122px;
            }

            .test-summary-meta,
            .test-summary-legend-item {
                font-size: 0.92rem;
            }
        }

        .inline-ai-btn {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            gap: 4px;
            min-height: 28px;
            padding: 0 10px;
            border-radius: 999px;
            border: 1.5px solid #bfdbfe;
            background: #ffffff;
            color: #1d4ed8;
            font-size: 10px;
            font-weight: 900;
            line-height: 1;
            white-space: nowrap;
            box-shadow: 0 2px 8px rgba(59, 130, 246, 0.12);
            cursor: pointer;
            transition: all 0.2s ease;
        }

        .inline-ai-btn:hover {
            background: #eff6ff;
            border-color: #93c5fd;
        }

        .inline-ai-btn.is-detailed {
            border-color: #c4b5fd;
            color: #6d28d9;
            box-shadow: 0 2px 8px rgba(139, 92, 246, 0.14);
        }

        .inline-ai-btn.is-detailed:hover {
            background: #f5f3ff;
            border-color: #a78bfa;
        }

        .context-menu-actions {
            padding: 4px 0;
        }

        .context-menu-row {
            display: flex;
            align-items: center;
            gap: 8px;
            border-bottom: 1px solid #f1f5f9;
        }

        .context-menu-btn.context-menu-btn-inline {
            width: auto;
            flex: 1 1 auto;
            border-bottom: none;
        }

        .context-menu-color {
            -webkit-appearance: none;
            appearance: none;
            width: 22px;
            height: 22px;
            padding: 0;
            margin-right: 8px;
            border: none;
            border-radius: 999px;
            background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.96) 0%, rgba(241, 245, 249, 0.9) 28%, rgba(203, 213, 225, 0.86) 100%);
            cursor: pointer;
            overflow: hidden;
            box-shadow: 0 8px 18px rgba(15, 23, 42, 0.14), inset 0 0 0 2px rgba(255, 255, 255, 0.94), 0 0 0 1px rgba(148, 163, 184, 0.34);
            transition: transform 0.18s ease, box-shadow 0.18s ease;
            flex: 0 0 auto;
        }

        .context-menu-color:hover {
            transform: translateY(-1px) scale(1.04);
            box-shadow: 0 14px 28px rgba(15, 23, 42, 0.2), inset 0 0 0 2px rgba(255, 255, 255, 0.96), 0 0 0 1px rgba(99, 102, 241, 0.28);
        }

        .context-menu-color:focus-visible {
            outline: none;
            box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.2), 0 12px 28px rgba(15, 23, 42, 0.18), inset 0 0 0 2px rgba(255, 255, 255, 0.96), 0 0 0 1px rgba(99, 102, 241, 0.34);
        }

        .context-menu-color::-webkit-color-swatch-wrapper {
            padding: 0;
            border-radius: 999px;
        }

        .context-menu-color::-webkit-color-swatch {
            border: none;
            border-radius: 999px;
        }

        .context-menu-color::-moz-color-swatch {
            border: none;
            border-radius: 999px;
        }

        .context-menu-actions .context-menu-btn {
            font-size: 11.6px;
            font-weight: 700;
        }

        .btn-ai-brief {
            background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
        }

        .btn-ai-detailed {
            background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%);
        }

        #total-qcm-input {
            appearance: textfield;
            -moz-appearance: textfield;
        }

        #total-qcm-input::-webkit-outer-spin-button,
        #total-qcm-input::-webkit-inner-spin-button {
            -webkit-appearance: none;
            margin: 0;
        }

        .simulation-title-actions-row {
            align-items: stretch !important;
        }

        .simulation-title-actions-row .simulation-field {
            flex-direction: row !important;
            align-items: center !important;
            gap: 8px !important;
        }

        .simulation-title-actions-row .simulation-field-label {
            min-height: 44px !important;
            margin-bottom: 0 !important;
            align-items: center !important;
            white-space: nowrap;
            flex: 0 0 auto;
        }

        .simulation-title-actions-row .simulation-field-input,
        .simulation-title-actions-row .simulation-primary-btn,
        .simulation-title-actions-row .simulation-pdf-btn,
        .simulation-title-actions-row .simulation-secondary-btn {
            min-height: 44px !important;
            height: 44px !important;
        }

        .simulation-title-actions-row .simulation-field-input {
            flex: 1 1 auto;
        }

        .simulation-title-actions-row .simulation-primary-btn,
        .simulation-title-actions-row .simulation-pdf-btn,
        .simulation-title-actions-row .simulation-secondary-btn {
            display: flex !important;
            align-items: center !important;
            justify-content: center !important;
        }

        .simulation-title-row-field,
        .simulation-title-count-field {
            align-self: stretch;
        }

        .simulation-title-count-field .simulation-field-input {
            text-align: center;
        }

        :root {
            --unified-filter-border: rgba(255, 255, 255, 0.96);
            --unified-filter-radius: 18px;
            --app-sidebar-expanded-width: 272px;
            --app-sidebar-collapsed-width: 78px;
        }

        .ms-btn,
        .ms-panel,
        .simulation-module-btn,
        .simulation-module-panel,
        .révision-filter-select,
        .révision-filter-dropdown,
        .filter-selection-panel,
        .simulation-inline-controls-grid .simulation-field-select,
        .simulation-module-controls-grid .simulation-field-select,
        .simulation-table-filters .simulation-field-select,
        .todo-filter-select,
        #srs-block .srs-filter-select {
            border-color: var(--unified-filter-border) !important;
            border-radius: var(--unified-filter-radius) !important;
        }

        #quiz-panel.test-workspace #qcm-control-extra-row > div:not([style*="width:1px"]),
        #quiz-panel.test-workspace #quality-rating-shell,
        #quiz-panel.test-workspace #difficulty-rating-shell,
        #quiz-panel.test-workspace #quiz-timers-row #quality-rating-shell,
        #quiz-panel.test-workspace #quiz-timers-row #difficulty-rating-shell,
        body.dark-theme #quiz-panel.test-workspace #qcm-control-extra-row > div:not([style*="width:1px"]),
        body.dark-theme #quiz-panel.test-workspace #quality-rating-shell,
        body.dark-theme #quiz-panel.test-workspace #difficulty-rating-shell,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #quality-rating-shell,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #difficulty-rating-shell {
            background: transparent !important;
            border: none !important;
            box-shadow: none !important;
            border-radius: 0 !important;
            padding: 0 !important;
        }

        #quiz-panel.test-workspace #quality-rating-shell > span,
        #quiz-panel.test-workspace #difficulty-rating-shell > span,
        #quiz-panel.test-workspace #quiz-timers-row #quality-rating-shell > span,
        #quiz-panel.test-workspace #quiz-timers-row #difficulty-rating-shell > span,
        body.dark-theme #quiz-panel.test-workspace #quality-rating-shell > span,
        body.dark-theme #quiz-panel.test-workspace #difficulty-rating-shell > span,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #quality-rating-shell > span,
        body.dark-theme #quiz-panel.test-workspace #quiz-timers-row #difficulty-rating-shell > span {
            background: transparent !important;
            border: none !important;
            box-shadow: none !important;
            border-radius: 0 !important;
            min-width: 0 !important;
            width: auto !important;
            height: auto !important;
            padding: 0 !important;
        }

        :root {
            --external-browser-width: min(50vw, 760px);
            --notes-browser-width: min(46vw, 720px);
        }

        #main-content {
            margin-left: var(--app-left-sidebar-width, 272px);
            transition: margin-left 0.28s ease, padding-right 0.28s ease, padding-left 0.28s ease;
        }

        body.mindmap-focus-active {
            padding-top: 0 !important;
            --app-left-sidebar-width: 0px;
            --app-global-topbar-left-edge: 0px;
        }

        body.mindmap-focus-active .app-global-top-bar,
        body.mindmap-focus-active #left-sidebar,
        body.mindmap-focus-active #sidebar-nav {
            display: none !important;
        }

        body.mindmap-focus-active #main-content {
            margin-left: 0 !important;
        }

        body.mindmap-focus-active #setup-section.test-workspace-active {
            padding-top: 0 !important;
        }

        body.split-companion-active {
            --app-left-sidebar-width: 0px;
            --app-global-topbar-left-edge: 0px;
        }

        body.split-companion-active #left-sidebar {
            display: none !important;
        }

        body.split-companion-active #main-content {
            margin-left: 0 !important;
            padding-left: 0 !important;
            padding-right: 0 !important;
        }

        body.split-companion-active .app-global-top-bar {
            display: flex !important;
        }

        body.split-companion-active #sidebar-nav.test-workspace-sidebar {
            display: none !important;
        }

        body.split-companion-active #setup-section.test-workspace-active {
            display: grid !important;
            grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
            gap: 10px;
            align-items: start;
            justify-content: stretch;
            padding-top: 0 !important;
            padding-bottom: 16px !important;
        }

        body.split-companion-active #setup-section.test-workspace-active > .split-companion-panel {
            grid-column: 1;
            min-height: 0 !important;
        }

        body.split-companion-active #setup-section.test-workspace-active > #quiz-panel.test-workspace.split-companion-qcm-panel {
            grid-column: 2;
            width: 100%;
            max-width: none;
            min-width: 0;
        }

        body.split-companion-active #quiz-panel.test-workspace.split-companion-qcm-panel {
            grid-template-columns: minmax(0, 1fr) !important;
        }

        body.split-companion-active #quiz-panel.test-workspace.split-companion-qcm-panel #quiz-info-column {
            display: none !important;
        }

        body.split-companion-active #setup-section.test-workspace-active > .split-companion-panel,
        body.split-companion-active #setup-section.test-workspace-active > #quiz-panel.test-workspace.split-companion-qcm-panel {
            min-height: calc(100vh - var(--app-top-banner-height, 0px));
            min-height: calc(100dvh - var(--app-top-banner-height, 0px));
        }

        body.split-companion-active .split-companion-panel {
            position: sticky !important;
            top: 0 !important;
            align-self: start;
            display: flex !important;
            flex-direction: column;
            width: 100% !important;
            min-width: 0;
            overflow: hidden;
            border: 1px solid rgba(226, 232, 240, 0.95) !important;
            border-radius: 18px !important;
            box-shadow: 0 18px 36px rgba(15, 23, 42, 0.14) !important;
            background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%) !important;
        }

        body.split-companion-active #notes-browser-panel.split-companion-panel,
        body.split-companion-active #external-browser-panel.split-companion-panel {
            position: fixed !important;
            top: 0 !important;
            left: 0 !important;
            right: calc(100vw - var(--workspace-split-qcm-left, 50vw) + 10px) !important;
            bottom: 0 !important;
            width: auto !important;
            height: 100vh !important;
            height: 100dvh !important;
            min-height: 100vh !important;
            min-height: 100dvh !important;
            max-height: 100vh !important;
            max-height: 100dvh !important;
            border-left: 1px solid rgba(226, 232, 240, 0.95) !important;
            border-right: 1px solid rgba(226, 232, 240, 0.95) !important;
            border-top-left-radius: 0 !important;
            border-top-right-radius: 0 !important;
            z-index: 4600 !important;
        }

        body.split-companion-active #notes-browser-panel.split-companion-panel .external-browser-header,
        body.split-companion-active #notes-browser-panel.split-companion-panel .external-browser-hint,
        body.split-companion-active #external-browser-panel.split-companion-panel .external-browser-header,
        body.split-companion-active #external-browser-panel.split-companion-panel .external-browser-hint {
            display: none !important;
        }

        body.split-companion-active #notes-browser-panel.split-companion-panel #notes-browser-frame,
        body.split-companion-active #external-browser-panel.split-companion-panel #external-browser-frame {
            flex: 1 1 auto;
            min-height: 0;
            height: 100%;
        }

        body.split-companion-active #main-content.external-browser-active,
        body.split-companion-active #main-content.notes-browser-active,
        #main-content.external-browser-active.external-browser-inline-active {
            padding-right: 0 !important;
            padding-left: 0 !important;
        }

        body.mindmap-focus-active:not(.mindmap-inline-panel-active):not(.split-companion-active) #quiz-panel.test-workspace {
            grid-template-columns: minmax(0, 1fr) !important;
        }

        body.mindmap-focus-active:not(.mindmap-inline-panel-active):not(.split-companion-active) #quiz-panel.test-workspace #quiz-info-column {
            display: none !important;
        }

        body.mindmap-inline-panel-active #quiz-panel.test-workspace {
            grid-template-columns: minmax(0, 1fr) minmax(340px, var(--external-browser-width)) !important;
            gap: 12px;
        }

        body.mindmap-inline-panel-active #quiz-panel.test-workspace #quiz-main-column {
            order: 1;
            min-width: 0;
        }

        body.mindmap-inline-panel-active #quiz-panel.test-workspace #quiz-info-column {
            order: 2;
            display: flex !important;
            flex-direction: column;
            min-width: 0;
            min-height: 0;
            align-self: stretch;
            overflow: visible;
        }

        #main-content.external-browser-active.external-browser-inline-active {
            padding-right: 0 !important;
        }

        #main-content.external-browser-active {
            padding-right: var(--external-browser-width);
        }

        #main-content.notes-browser-active {
            padding-left: var(--notes-browser-width);
        }

        #notes-browser-panel {
            position: absolute;
            top: 0;
            left: 0;
            bottom: 0;
            width: var(--notes-browser-width);
            display: none;
            flex-direction: column;
            background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
            border-right: 1px solid rgba(226, 232, 240, 0.95);
            box-shadow: 20px 0 38px rgba(15, 23, 42, 0.14);
            z-index: 60;
            overflow: hidden;
        }

        #notes-browser-panel.active {
            display: flex;
        }

        #external-browser-panel {
            position: absolute;
            top: 0;
            right: 0;
            bottom: 0;
            width: var(--external-browser-width);
            display: none;
            flex-direction: column;
            background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
            border-left: 1px solid rgba(226, 232, 240, 0.95);
            box-shadow: -20px 0 38px rgba(15, 23, 42, 0.14);
            z-index: 60;
            overflow: hidden;
        }

        #external-browser-panel.active {
            display: flex;
        }

        body.split-companion-active #external-browser-panel.inline-workspace-panel {
            position: sticky;
            top: 4px;
            right: auto;
            bottom: auto;
            width: 100%;
            min-width: 0;
            min-height: calc(100vh - 8px);
            min-height: calc(100dvh - 8px);
            height: calc(100vh - 8px);
            height: calc(100dvh - 8px);
            border-left: 0;
            border: 1px solid rgba(226, 232, 240, 0.95);
            border-radius: 18px;
            box-shadow: 0 18px 36px rgba(15, 23, 42, 0.14);
            z-index: 1;
        }

        body.mindmap-inline-panel-active #external-browser-panel.inline-workspace-panel {
            position: sticky;
            top: 4px;
            right: auto;
            bottom: auto;
            width: 100%;
            min-width: 0;
            min-height: calc(100vh - 8px);
            min-height: calc(100dvh - 8px);
            height: calc(100vh - 8px);
            height: calc(100dvh - 8px);
            border-left: 0;
            border: 1px solid rgba(226, 232, 240, 0.95);
            border-radius: 18px;
            box-shadow: 0 18px 36px rgba(15, 23, 42, 0.14);
            z-index: 1;
        }

        body.mindmap-inline-panel-active #quiz-panel.test-workspace #quiz-info-column > #external-browser-panel.inline-workspace-panel {
            flex: 1 1 auto;
        }

        #external-browser-panel.is-mindmap .external-browser-header,
        #external-browser-panel.is-mindmap .external-browser-hint {
            display: none;
        }

        .external-browser-header {
            display: flex;
            align-items: flex-start;
            justify-content: space-between;
            gap: 12px;
            padding: 12px 14px;
            border-bottom: 1px solid rgba(226, 232, 240, 0.95);
            background: linear-gradient(135deg, #eff6ff 0%, #f8fafc 100%);
        }

        .notes-browser-header {
            background: linear-gradient(135deg, #fff7ed 0%, #f8fafc 100%);
        }

        .external-browser-head-copy {
            min-width: 0;
            display: grid;
            gap: 4px;
        }

        .external-browser-title-row {
            display: flex;
            align-items: center;
            gap: 10px;
            min-width: 0;
        }

        .external-browser-badge {
            width: 36px;
            height: 36px;
            border-radius: 12px;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
            color: #ffffff;
            box-shadow: 0 10px 22px rgba(37, 99, 235, 0.24);
            flex: 0 0 auto;
        }

        #external-browser-title {
            font-size: 14px;
            font-weight: 900;
            color: #0f172a;
            line-height: 1.1;
        }

        #external-browser-subtitle {
            font-size: 10px;
            font-weight: 700;
            color: #475569;
            line-height: 1.2;
        }

        #external-browser-url {
            max-width: 100%;
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;
            font-size: 9px;
            font-weight: 700;
            color: #64748b;
        }

        .external-browser-actions {
            display: flex;
            align-items: center;
            gap: 8px;
            flex: 0 0 auto;
        }

        .external-browser-action-btn {
            border: 1px solid rgba(148, 163, 184, 0.36);
            background: #ffffff;
            color: #334155;
            border-radius: 999px;
            padding: 7px 10px;
            font-size: 10px;
            font-weight: 800;
            line-height: 1;
            display: inline-flex;
            align-items: center;
            gap: 6px;
            cursor: pointer;
            transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
        }

        .external-browser-action-btn:hover {
            transform: translateY(-1px);
            box-shadow: 0 10px 20px rgba(15, 23, 42, 0.08);
        }

        .external-browser-action-btn.is-close {
            background: linear-gradient(135deg, #fee2e2 0%, #ffffff 100%);
            color: #b91c1c;
            border-color: rgba(239, 68, 68, 0.28);
        }

        .external-browser-hint {
            padding: 8px 14px;
            border-bottom: 1px solid rgba(226, 232, 240, 0.82);
            background: #fff7ed;
            color: #9a3412;
            font-size: 9px;
            font-weight: 700;
            line-height: 1.35;
        }

        #external-browser-frame {
            flex: 1 1 auto;
            width: 100%;
            min-height: 0;
            border: 0;
            background: #ffffff;
        }

        #external-browser-panel.is-mindmap #external-browser-frame {
            height: 100%;
        }

        body.mindmap-inline-panel-active #external-browser-panel.inline-workspace-panel #external-browser-frame {
            min-height: 0;
            height: 100%;
        }

        body.dark-theme #external-browser-panel {
            background: linear-gradient(180deg, #0f172a 0%, #111827 100%);
            border-left-color: rgba(71, 85, 105, 0.55);
            box-shadow: -22px 0 42px rgba(2, 6, 23, 0.45);
        }

        body.dark-theme #notes-browser-panel {
            background: linear-gradient(180deg, #0f172a 0%, #111827 100%);
            border-right-color: rgba(71, 85, 105, 0.55);
            box-shadow: 22px 0 42px rgba(2, 6, 23, 0.45);
        }

        body.dark-theme .external-browser-header {
            background: linear-gradient(135deg, rgba(30, 41, 59, 0.96) 0%, rgba(15, 23, 42, 0.98) 100%);
            border-bottom-color: rgba(51, 65, 85, 0.92);
        }

        body.dark-theme .notes-browser-header {
            background: linear-gradient(135deg, rgba(51, 65, 85, 0.96) 0%, rgba(15, 23, 42, 0.98) 100%);
        }

        body.dark-theme #external-browser-title {
            color: #e2e8f0;
        }

        body.dark-theme #external-browser-subtitle,
        body.dark-theme #external-browser-url {
            color: #94a3b8;
        }

        body.dark-theme .external-browser-action-btn {
            background: rgba(15, 23, 42, 0.96);
            color: #e2e8f0;
            border-color: rgba(148, 163, 184, 0.22);
        }

        body.dark-theme .external-browser-hint {
            background: rgba(124, 45, 18, 0.32);
            color: #fed7aa;
            border-bottom-color: rgba(124, 45, 18, 0.45);
        }

        body.dark-theme #external-browser-frame {
            background: #0f172a;
        }

        @media (max-width: 980px) {
            :root {
                --external-browser-width: 100%;
                --notes-browser-width: 100%;
            }

            #main-content.external-browser-active {
                padding-right: 0;
            }

            #main-content.notes-browser-active {
                padding-left: 0;
            }

            #external-browser-panel {
                border-left: none;
                box-shadow: none;
            }

            #notes-browser-panel {
                border-right: none;
                box-shadow: none;
            }
        }

        @media (max-width: 768px) {
            body.qcm-workspace-active #btn-study-main,
            body.qcm-workspace-active #btn-study-side {
                display: none !important;
            }

            body.qcm-workspace-active #quiz-panel.test-workspace #btn-study-main {
                display: flex !important;
            }
        }

        @media (max-width: 768px) {
            :root {
                --qcm-mobile-bottom-clearance: calc(104px + env(safe-area-inset-bottom, 0px));
            }

            #mobile-study-eye-btn {
                position: fixed;
                right: 14px;
                bottom: calc(96px + env(safe-area-inset-bottom, 0px));
                z-index: 3655;
                width: 52px;
                height: 52px;
                border: none;
                border-radius: 16px;
                background: linear-gradient(135deg, #0f766e 0%, #14b8a6 100%);
                color: #ffffff;
                display: none !important;
                align-items: center;
                justify-content: center;
                box-shadow: 0 18px 30px rgba(15, 118, 110, 0.32);
            }

            body.mobile-study-enabled.qcm-workspace-active #mobile-study-eye-btn {
                display: inline-flex !important;
            }

            body.mobile-study-panel-open #mobile-study-eye-btn {
                background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
                box-shadow: 0 18px 30px rgba(15, 23, 42, 0.28);
            }

            #mobile-study-panel {
                position: fixed;
                inset: 0;
                z-index: 3650;
                display: none !important;
                background: #ffffff;
                padding-top: var(--app-top-safe-offset, 0px);
            }

            body.mobile-study-panel-open #mobile-study-panel {
                display: block !important;
            }

            #mobile-study-panel iframe {
                width: 100%;
                height: 100%;
                border: 0;
                background: #ffffff;
                display: block;
            }

            body.dark-theme #mobile-study-panel {
                background: #0f172a;
            }

            #setup-section {
                padding-bottom: var(--qcm-mobile-bottom-clearance) !important;
                scroll-padding-bottom: var(--qcm-mobile-bottom-clearance) !important;
            }

            #main-content,
            #setup-panel,
            #quiz-panel.test-workspace,
            #quiz-panel.test-workspace #quiz-main-column {
                scroll-padding-bottom: var(--qcm-mobile-bottom-clearance);
            }

            #setup-panel::after {
                content: "";
                display: block;
                width: 100%;
                height: 8px;
            }

            .mobile-sidebar-bottom-nav {
                touch-action: auto;
            }
        }

        #quiz-panel.test-workspace #qcm-control-main-row > button,
        #quiz-panel.test-workspace #qcm-main-translate-host .large-translate-btn,
        #quiz-panel.test-workspace .question-actions-after-options > button,
        #quiz-panel.test-workspace .inline-ai-btn,
        #quiz-panel.test-workspace .inline-verify-btn,
        #quiz-panel.test-workspace .inline-todo-btn,
        #quiz-panel.test-workspace .inline-next-btn {
            min-height: var(--qcm-unified-action-height, 0.5cm) !important;
            height: var(--qcm-unified-action-height, 0.5cm) !important;
            max-height: var(--qcm-unified-action-height, 0.5cm) !important;
            padding: 0 10px !important;
            padding-top: 0 !important;
            padding-bottom: 0 !important;
            border: none !important;
            box-shadow: none !important;
            outline: none !important;
            display: inline-flex !important;
            align-items: center !important;
            justify-content: center !important;
            line-height: 1 !important;
            box-sizing: border-box !important;
        }

        #quiz-panel.test-workspace #qcm-control-main-row > button:hover,
        #quiz-panel.test-workspace #qcm-control-main-row > button:focus,
        #quiz-panel.test-workspace #qcm-main-translate-host .large-translate-btn:hover,
        #quiz-panel.test-workspace #qcm-main-translate-host .large-translate-btn:focus,
        #quiz-panel.test-workspace .inline-ai-btn:hover,
        #quiz-panel.test-workspace .inline-ai-btn:focus,
        #quiz-panel.test-workspace .inline-verify-btn:hover,
        #quiz-panel.test-workspace .inline-verify-btn:focus,
        #quiz-panel.test-workspace .inline-todo-btn:hover,
        #quiz-panel.test-workspace .inline-todo-btn:focus,
        #quiz-panel.test-workspace .inline-next-btn:hover,
        #quiz-panel.test-workspace .inline-next-btn:focus {
            border: none !important;
            box-shadow: none !important;
            outline: none !important;
        }

        @media (min-width: 769px) {
            body.qcm-workspace-active {
                --workspace-topbar-ghost-text: rgba(255, 255, 255, 0.98);
                --workspace-topbar-ghost-muted: rgba(255, 255, 255, 0.82);
                --workspace-topbar-ghost-border: rgba(255, 255, 255, 0.52);
                --workspace-topbar-ghost-fill-hover: rgba(255, 255, 255, 0.12);
                --workspace-topbar-ghost-fill-active: rgba(255, 255, 255, 0.22);
            }

            body.qcm-workspace-active #workspace-topbar-row-1 #quiz-timers-row .mini-timer-pill,
            body.qcm-workspace-active #workspace-topbar-row-1 #quick-search-wrapper,
            body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pill,
            body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip,
            body.qcm-workspace-active #workspace-topbar-row-2 .filter-badge,
            body.qcm-workspace-active #workspace-topbar-row-2 #qcm-control-extra-row,
            body.qcm-workspace-active #workspace-topbar-row-3 #qcm-control-main-row > button,
            body.qcm-workspace-active #workspace-topbar-row-3 #qcm-main-translate-host .large-translate-btn,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-ai-btn,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-verify-btn,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-todo-btn,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-next-btn {
                background: transparent !important;
                border: 1px solid var(--workspace-topbar-ghost-border) !important;
                box-shadow: none !important;
                color: var(--workspace-topbar-ghost-text) !important;
                text-shadow: none !important;
                transition: background-color 0.18s ease, color 0.18s ease !important;
            }

            body.qcm-workspace-active #workspace-topbar-row-1 #révision-details .question-day-chip,
            body.qcm-workspace-active #workspace-topbar-row-1 #révision-count,
            body.qcm-workspace-active #workspace-topbar-row-1 #révision-correct-total,
            body.qcm-workspace-active #workspace-topbar-row-1 #révision-wrong-total,
            body.qcm-workspace-active #workspace-topbar-row-1 #session-score-pill,
            body.qcm-workspace-active #workspace-topbar-row-2 #qcm-control-extra-row {
                border: 1px solid var(--workspace-topbar-ghost-border) !important;
            }

            body.qcm-workspace-active #workspace-topbar-row-1 #quick-search-wrapper {
                border-radius: 999px !important;
                padding: 0 10px !important;
            }

            body.qcm-workspace-active #workspace-topbar-row-1 #question-stats {
                background: transparent !important;
                border: none !important;
                border-radius: 0 !important;
                box-shadow: none !important;
                padding: 0 !important;
            }

            body.qcm-workspace-active #workspace-topbar-row-2 #qcm-control-extra-row {
                min-height: 22px !important;
                height: 22px !important;
            }

            body.qcm-workspace-active #workspace-topbar-row-1 #desktop-quick-search-input {
                background: transparent !important;
                border: none !important;
                box-shadow: none !important;
                color: var(--workspace-topbar-ghost-text) !important;
                caret-color: #ffffff !important;
            }

            body.qcm-workspace-active #workspace-topbar-row-1 #desktop-quick-search-input::placeholder {
                color: rgba(255, 255, 255, 0.82) !important;
            }

            body.qcm-workspace-active #workspace-topbar-row-1 #quiz-timers-row .mini-timer-pill i,
            body.qcm-workspace-active #workspace-topbar-row-1 #quiz-timers-row .mini-timer-pill span,
            body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pill,
            body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip,
            body.qcm-workspace-active #workspace-topbar-row-2 .filter-badge,
            body.qcm-workspace-active #workspace-topbar-row-2 .filter-badge-label,
            body.qcm-workspace-active #workspace-topbar-row-2 .filter-badge i,
            body.qcm-workspace-active #workspace-topbar-row-3 #qcm-control-main-row > button,
            body.qcm-workspace-active #workspace-topbar-row-3 #qcm-control-main-row > button i,
            body.qcm-workspace-active #workspace-topbar-row-3 #qcm-main-translate-host .large-translate-btn,
            body.qcm-workspace-active #workspace-topbar-row-3 #qcm-main-translate-host .large-translate-btn i,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-ai-btn,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-ai-btn i,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-verify-btn,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-verify-btn i,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-todo-btn,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-todo-btn i,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-next-btn,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-next-btn i {
                color: var(--workspace-topbar-ghost-text) !important;
            }

            body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pill.neutral,
            body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pill.success,
            body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pill.danger,
            body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pill.info,
            body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip.empty,
            body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip.correct-only,
            body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip.wrong-only,
            body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip.mixed {
                background: transparent !important;
                border: 1px solid var(--workspace-topbar-ghost-border) !important;
                box-shadow: none !important;
                color: var(--workspace-topbar-ghost-text) !important;
            }

            body.qcm-workspace-active #workspace-topbar-row-2 #qcm-control-extra-row,
            body.qcm-workspace-active #workspace-topbar-row-2 #quality-rating-shell,
            body.qcm-workspace-active #workspace-topbar-row-2 #difficulty-rating-shell {
                background: transparent !important;
                border: none !important;
                box-shadow: none !important;
            }

            body.qcm-workspace-active #workspace-topbar-row-2 #difficulty-rating-shell {
                padding-left: 4px !important;
                border-left: none !important;
            }

            body.qcm-workspace-active #workspace-topbar-row-2 #quality-rating-shell > span,
            body.qcm-workspace-active #workspace-topbar-row-2 #difficulty-rating-shell > span {
                color: var(--workspace-topbar-ghost-text) !important;
            }

            body.qcm-workspace-active #workspace-topbar-row-2 #rating-quality .large-star,
            body.qcm-workspace-active #workspace-topbar-row-2 #rating-difficulty .large-star {
                color: rgba(255, 255, 255, 0.42) !important;
            }

            body.qcm-workspace-active #workspace-topbar-row-2 #rating-quality .large-star.active,
            body.qcm-workspace-active #workspace-topbar-row-2 #rating-difficulty .large-star.active,
            body.qcm-workspace-active #workspace-topbar-row-2 #rating-quality .large-star:hover,
            body.qcm-workspace-active #workspace-topbar-row-2 #rating-difficulty .large-star:hover,
            body.qcm-workspace-active #workspace-topbar-row-2 #rating-quality .large-star:active,
            body.qcm-workspace-active #workspace-topbar-row-2 #rating-difficulty .large-star:active {
                color: #ffffff !important;
            }

            body.qcm-workspace-active #workspace-topbar-row-1 #quiz-timers-row .mini-timer-pill:hover,
            body.qcm-workspace-active #workspace-topbar-row-1 #quick-search-wrapper:hover,
            body.qcm-workspace-active #workspace-topbar-row-1 #quick-search-wrapper:focus-within,
            body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pill:hover,
            body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip:hover,
            body.qcm-workspace-active #workspace-topbar-row-2 .filter-badge:hover,
            body.qcm-workspace-active #workspace-topbar-row-2 .filter-badge.filter-badge-open,
            body.qcm-workspace-active #workspace-topbar-row-2 .filter-badge.active,
            body.qcm-workspace-active #workspace-topbar-row-2 #qcm-control-extra-row:hover,
            body.qcm-workspace-active #workspace-topbar-row-2 #quality-rating-shell:hover,
            body.qcm-workspace-active #workspace-topbar-row-2 #difficulty-rating-shell:hover,
            body.qcm-workspace-active #workspace-topbar-row-3 #qcm-control-main-row > button:hover,
            body.qcm-workspace-active #workspace-topbar-row-3 #qcm-control-main-row > button:focus-visible,
            body.qcm-workspace-active #workspace-topbar-row-3 #qcm-main-translate-host .large-translate-btn:hover,
            body.qcm-workspace-active #workspace-topbar-row-3 #qcm-main-translate-host .large-translate-btn:focus-visible,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-ai-btn:hover,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-ai-btn:focus-visible,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-verify-btn:hover,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-verify-btn:focus-visible,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-todo-btn:hover,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-todo-btn:focus-visible,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-next-btn:hover,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-next-btn:focus-visible {
                background: var(--workspace-topbar-ghost-fill-hover) !important;
            }

            body.qcm-workspace-active #workspace-topbar-row-1 #quiz-timers-row .mini-timer-pill:active,
            body.qcm-workspace-active #workspace-topbar-row-1 #quick-search-wrapper:active,
            body.qcm-workspace-active #workspace-topbar-row-2 .filter-badge:active,
            body.qcm-workspace-active #workspace-topbar-row-2 #qcm-control-extra-row:active,
            body.qcm-workspace-active #workspace-topbar-row-2 #quality-rating-shell:active,
            body.qcm-workspace-active #workspace-topbar-row-2 #difficulty-rating-shell:active,
            body.qcm-workspace-active #workspace-topbar-row-3 #qcm-control-main-row > button:active,
            body.qcm-workspace-active #workspace-topbar-row-3 #qcm-main-translate-host .large-translate-btn:active,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-ai-btn:active,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-verify-btn:active,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-todo-btn:active,
            body.qcm-workspace-active #workspace-topbar-row-3 .inline-next-btn:active {
                background: var(--workspace-topbar-ghost-fill-active) !important;
            }
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame {
            display: flex !important;
            align-items: center !important;
            gap: 6px !important;
            flex: 1 1 auto !important;
            min-width: 0 !important;
            min-height: var(--workspace-topbar-item-height) !important;
            padding: 4px 6px !important;
            border-radius: 14px !important;
            border: 2px solid #ffffff !important;
            background: transparent !important;
            box-shadow: none !important;
            box-sizing: border-box !important;
            overflow-x: auto !important;
            overflow-y: hidden !important;
            scrollbar-gutter: stable;
            scrollbar-width: thin;
            scrollbar-color: rgba(255, 255, 255, 0.95) rgba(255, 255, 255, 0.16);
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-side-pills {
            display: none !important;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-details,
        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-count,
        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-correct-total,
        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-wrong-total,
        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #session-score-pill {
            border: 1px solid #d8e1ea !important;
            background: #ffffff !important;
            box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06) !important;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame::-webkit-scrollbar {
            height: 6px;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame::-webkit-scrollbar-track {
            background: rgba(255, 255, 255, 0.16);
            border-radius: 999px;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame::-webkit-scrollbar-thumb {
            background: rgba(255, 255, 255, 0.92);
            border-radius: 999px;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-details {
            display: flex !important;
            align-items: center !important;
            gap: 6px !important;
            flex: 0 0 auto !important;
            min-width: max-content !important;
            width: max-content !important;
            max-width: none !important;
            min-height: calc(var(--workspace-topbar-item-height) - 8px) !important;
            padding: 0 10px !important;
            border-radius: 10px !important;
            color: #7f1d1d !important;
            overflow: visible !important;
            scrollbar-width: none;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-details::-webkit-scrollbar {
            display: none;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pills {
            gap: 6px !important;
            padding: 0 !important;
            overflow: visible !important;
            flex: 0 0 auto !important;
            width: max-content !important;
            white-space: nowrap !important;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-count,
        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-correct-total,
        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-wrong-total,
        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #session-score-pill {
            min-height: calc(var(--workspace-topbar-item-height) - 8px) !important;
            padding: 0 12px !important;
            border-radius: 10px !important;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-count {
            color: #475569 !important;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-correct-total {
            color: #15803d !important;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-wrong-total {
            color: #dc2626 !important;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #session-score-pill {
            color: #1d4ed8 !important;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-details .question-day-chip {
            min-height: 0 !important;
            padding: 0 !important;
            border: none !important;
            border-radius: 0 !important;
            background: transparent !important;
            box-shadow: none !important;
            color: inherit !important;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-details .question-day-chip + .question-day-chip {
            padding-left: 6px !important;
            margin-left: 6px !important;
            border-left: 1px solid rgba(127, 29, 29, 0.18) !important;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-details .question-day-chip.correct-only {
            color: #166534 !important;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-details .question-day-chip.wrong-only {
            color: #b91c1c !important;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-details .question-day-chip.mixed {
            color: #c2410c !important;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-details .question-day-chip.empty {
            min-width: 0 !important;
            max-width: 100% !important;
            color: #64748b !important;
            overflow: hidden !important;
            text-overflow: ellipsis !important;
            white-space: nowrap !important;
            justify-content: flex-start !important;
        }

        body.qcm-workspace-active #qcm-inline-actions-host {
            height: var(--workspace-inline-button-height, var(--workspace-topbar-button-height, 32px)) !important;
            min-height: var(--workspace-inline-button-height, var(--workspace-topbar-button-height, 32px)) !important;
            max-height: var(--workspace-inline-button-height, var(--workspace-topbar-button-height, 32px)) !important;
            align-items: center !important;
            overflow: visible !important;
        }

        body.qcm-workspace-active #qcm-inline-actions-host .question-actions-after-options {
            display: flex !important;
            align-items: stretch !important;
            justify-content: flex-start !important;
            flex-wrap: nowrap !important;
            gap: 4px !important;
            margin: 0 !important;
            padding: 0 !important;
            height: var(--workspace-inline-button-height, var(--workspace-topbar-button-height, 32px)) !important;
            min-height: var(--workspace-inline-button-height, var(--workspace-topbar-button-height, 32px)) !important;
            max-height: var(--workspace-inline-button-height, var(--workspace-topbar-button-height, 32px)) !important;
            overflow: visible !important;
        }

        body.qcm-workspace-active #qcm-inline-actions-host .question-actions-after-options > button {
            align-self: stretch !important;
            min-height: var(--workspace-inline-button-height, var(--workspace-topbar-button-height, 32px)) !important;
            height: var(--workspace-inline-button-height, var(--workspace-topbar-button-height, 32px)) !important;
            max-height: var(--workspace-inline-button-height, var(--workspace-topbar-button-height, 32px)) !important;
            margin: 0 !important;
            padding: 0 11px !important;
            border-radius: 16px !important;
        }

        #workspace-topbar-row-4 {
            display: none;
        }

        body.qcm-workspace-active #workspace-topbar-row-4 {
            display: none;
            width: 100%;
            min-width: 0;
            height: auto;
            min-height: 0;
            flex: 0 0 auto;
            align-items: stretch;
            justify-content: stretch;
            overflow: visible;
        }

        body.qcm-workspace-active #workspace-topbar-row-4.is-visible {
            display: flex;
            height: 0;
            min-height: 0;
            flex: 0 0 0;
        }

        .schema-workspace-panel-host {
            position: fixed;
            inset: 0;
            z-index: 9200;
            display: flex;
            align-items: stretch;
            justify-content: stretch;
            width: 100vw;
            height: 100vh;
            height: 100dvh;
            min-width: 0;
            pointer-events: auto;
        }

        .schema-workspace-backdrop {
            position: absolute;
            inset: 0;
            padding: 0;
            border: none;
            background:
                radial-gradient(circle at top, rgba(99, 102, 241, 0.16), transparent 34%),
                linear-gradient(180deg, rgba(15, 23, 42, 0.72) 0%, rgba(15, 23, 42, 0.84) 100%);
            backdrop-filter: blur(12px);
            cursor: pointer;
        }

        #btn-schema-main.is-active {
            background: #eef2ff !important;
            color: #4338ca !important;
            border-color: #a5b4fc !important;
        }

        .schema-slider-shell {
            position: relative;
            z-index: 1;
            display: grid;
            grid-template-columns: 70px minmax(0, 1fr) 70px;
            grid-template-rows: auto minmax(0, 1fr);
            grid-template-areas:
                "header header header"
                "prev stage next";
            align-items: stretch;
            gap: 18px;
            width: 100vw;
            height: 100vh;
            height: 100dvh;
            padding: 20px;
            background:
                linear-gradient(180deg, rgba(248, 250, 252, 0.94) 0%, rgba(226, 232, 240, 0.9) 100%);
            box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
        }

        .schema-slider-header {
            grid-area: header;
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 14px;
            min-width: 0;
        }

        .schema-slider-heading {
            display: flex;
            align-items: center;
            gap: 12px;
            min-width: 0;
            flex-wrap: wrap;
        }

        .schema-slider-title {
            font-size: clamp(22px, 2.3vw, 32px);
            font-weight: 900;
            color: #0f172a;
            letter-spacing: -0.03em;
        }

        .schema-slider-subtitle {
            font-size: 13px;
            font-weight: 800;
            color: #64748b;
            white-space: nowrap;
        }

        .schema-slider-toolbar {
            display: flex;
            align-items: center;
            justify-content: flex-end;
            gap: 10px;
            flex-wrap: wrap;
        }

        .schema-toolbar-btn {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            min-height: 44px;
            padding: 0 16px;
            border: none;
            border-radius: 999px;
            background: rgba(255, 255, 255, 0.96);
            color: #334155;
            box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08);
            font-size: 13px;
            font-weight: 900;
            cursor: pointer;
            transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, color 0.18s ease;
        }

        .schema-toolbar-btn:hover:not(:disabled) {
            transform: translateY(-1px);
            box-shadow: 0 14px 26px rgba(15, 23, 42, 0.12);
        }

        .schema-toolbar-btn:disabled {
            opacity: 0.42;
            cursor: default;
            box-shadow: none;
        }

        .schema-toolbar-btn.is-primary {
            background: #eef2ff;
            color: #4338ca;
        }

        .schema-toolbar-btn.is-danger {
            background: #fee2e2;
            color: #b91c1c;
        }

        .schema-toolbar-btn.is-close {
            background: #0f172a;
            color: #ffffff;
        }

        .schema-nav-btn {
            grid-area: prev;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            align-self: center;
            justify-self: center;
            width: 58px;
            height: 58px;
            border: none;
            border-radius: 999px;
            background: rgba(255, 255, 255, 0.96);
            color: #475569;
            cursor: pointer;
            box-shadow: 0 16px 30px rgba(15, 23, 42, 0.12);
            transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
            font-size: 18px;
        }

        .schema-nav-btn.is-next {
            grid-area: next;
        }

        .schema-nav-btn:hover:not(:disabled) {
            background: #eff6ff;
            transform: translateY(-1px);
            color: #1d4ed8;
            box-shadow: 0 18px 34px rgba(37, 99, 235, 0.16);
        }

        .schema-nav-btn:disabled {
            opacity: 0.42;
            cursor: default;
            box-shadow: none;
        }

        .schema-stage {
            grid-area: stage;
            min-width: 0;
            min-height: 0;
            display: flex;
            align-items: stretch;
            justify-content: center;
        }

        .schema-stage-card {
            display: flex;
            flex-direction: column;
            align-items: stretch;
            justify-content: center;
            gap: 16px;
            flex: 1 1 auto;
            width: min(100%, 1400px);
            min-width: 0;
            min-height: 0;
            max-height: 100%;
            padding: 22px;
            border: 1px solid rgba(203, 213, 225, 0.72);
            border-radius: 28px;
            background: linear-gradient(180deg, rgba(255, 255, 255, 0.99) 0%, rgba(241, 245, 249, 0.96) 100%);
            box-shadow: 0 26px 52px rgba(15, 23, 42, 0.12);
            text-align: center;
        }

        .schema-stage-meta {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 10px;
            width: 100%;
            font-size: 14px;
            font-weight: 800;
            color: #475569;
        }

        .schema-slide-count {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            min-height: 34px;
            padding: 0 14px;
            border-radius: 999px;
            background: #eef2ff;
            color: #4338ca;
            font-size: 12px;
            font-weight: 900;
        }

        .schema-add-btn {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            align-self: center;
            min-height: 48px;
            padding: 0 20px;
            border: none;
            border-radius: 999px;
            background: #eef2ff;
            color: #4338ca;
            font-size: 14px;
            font-weight: 900;
            cursor: pointer;
            box-shadow: 0 16px 28px rgba(79, 70, 229, 0.14);
            transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
        }

        .schema-add-btn:hover {
            transform: translateY(-1px);
            box-shadow: 0 18px 32px rgba(79, 70, 229, 0.18);
        }

        .schema-stage-hint {
            font-size: 11px;
            font-weight: 700;
            color: #64748b;
        }

        .schema-image-wrap {
            width: 100%;
            display: flex;
            align-items: center;
            justify-content: center;
            flex: 1 1 auto;
            min-height: 0;
            overflow: hidden;
            border-radius: 22px;
            background:
                linear-gradient(180deg, rgba(248, 250, 252, 0.96) 0%, rgba(226, 232, 240, 0.92) 100%);
            padding: 18px;
        }

        .schema-slide-image {
            display: block;
            max-width: 100%;
            max-height: 100%;
            object-fit: contain;
            border-radius: 18px;
            box-shadow: 0 18px 36px rgba(148, 163, 184, 0.22);
            background: #ffffff;
        }

        .schema-empty-state {
            font-size: 15px;
            font-weight: 800;
            color: #64748b;
        }

        @media (max-width: 768px) {
            .schema-slider-shell {
                grid-template-columns: 52px minmax(0, 1fr) 52px;
                gap: 12px;
                padding: max(12px, env(safe-area-inset-top)) 12px max(12px, env(safe-area-inset-bottom)) 12px;
            }

            .schema-slider-header {
                gap: 10px;
                align-items: flex-start;
            }

            .schema-slider-title {
                font-size: 18px;
            }

            .schema-slider-subtitle {
                font-size: 11px;
            }

            .schema-slider-toolbar {
                gap: 8px;
            }

            .schema-toolbar-btn,
            .schema-add-btn {
                min-height: 38px;
                padding: 0 13px;
                font-size: 11px;
            }

            .schema-nav-btn {
                width: 46px;
                height: 46px;
                font-size: 15px;
            }

            .schema-stage-card {
                padding: 12px;
                border-radius: 20px;
                gap: 12px;
            }

            .schema-slide-image {
                border-radius: 14px;
            }
        }

        #setup-section:not(.test-workspace-active) {
            align-items: stretch !important;
            padding-top: 0 !important;
            padding-right: 0 !important;
            padding-left: 0 !important;
            scrollbar-gutter: stable;
        }

        #setup-section:not(.test-workspace-active) #setup-panel {
            padding-top: 0 !important;
            padding-left: 24px !important;
            padding-right: 24px !important;
            box-sizing: border-box !important;
        }

        #setup-section:not(.test-workspace-active) .simulation-shell {
            gap: 14px;
            padding-top: 0;
            padding-bottom: 8px;
        }

        #setup-section:not(.test-workspace-active) .simulation-hero-card,
        #setup-section:not(.test-workspace-active) .simulation-tabs,
        #setup-section:not(.test-workspace-active) .simulation-grid,
        #setup-section:not(.test-workspace-active) .simulation-panel,
        #setup-section:not(.test-workspace-active) .simulation-panel-head,
        #setup-section:not(.test-workspace-active) .simulation-panel-body {
            position: relative !important;
            top: auto !important;
        }

        body:not(.dark-theme).qcm-workspace-active {
            --workspace-topbar-ghost-text: #334155;
            --workspace-topbar-ghost-muted: #64748b;
            --workspace-topbar-ghost-border: rgba(203, 213, 225, 0.96);
            --workspace-topbar-ghost-fill-hover: rgba(241, 245, 249, 0.96);
            --workspace-topbar-ghost-fill-active: rgba(226, 232, 240, 0.96);
        }

        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #quiz-info-column,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #quiz-main-column,
        body:not(.dark-theme).qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card-wrapper,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card .question-card-body,
        body:not(.dark-theme).qcm-workspace-active .question-comment-card,
        body:not(.dark-theme).qcm-workspace-active .question-comment-head,
        body:not(.dark-theme).qcm-workspace-active .question-comment-input,
        body:not(.dark-theme).qcm-workspace-active .question-comment-actions,
        body:not(.dark-theme).qcm-workspace-active .question-comment-empty,
        body:not(.dark-theme).qcm-workspace-active .question-comment-footer-spacer,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #quiz-timers-row .mini-timer-pill,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #quick-search-wrapper,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pill,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-2 .filter-badge,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-2 #qcm-control-extra-row,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 #qcm-control-main-row > button,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 #qcm-main-translate-host .large-translate-btn,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-ai-btn,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-verify-btn,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-todo-btn,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-next-btn {
            background: #ffffff !important;
            background-image: none !important;
            border-color: #d9e2ec !important;
            box-shadow: 0 8px 20px rgba(148, 163, 184, 0.08) !important;
        }

        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #desktop-quick-search-input,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #desktop-quick-search-input::placeholder,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #quiz-timers-row .mini-timer-pill i,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #quiz-timers-row .mini-timer-pill span,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-2 .filter-badge,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-2 .filter-badge i,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-2 .filter-badge-label,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 #qcm-control-main-row > button,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 #qcm-control-main-row > button i,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 #qcm-main-translate-host .large-translate-btn,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 #qcm-main-translate-host .large-translate-btn i,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-ai-btn,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-ai-btn i,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-verify-btn,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-verify-btn i,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-todo-btn,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-todo-btn i,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-next-btn,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-next-btn i,
        body:not(.dark-theme).qcm-workspace-active .question-comment-title,
        body:not(.dark-theme).qcm-workspace-active .question-comment-action-hint,
        body:not(.dark-theme).qcm-workspace-active .question-comment-empty {
            color: #334155 !important;
        }

        body:not(.dark-theme).qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong,
        body:not(.dark-theme).qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong,
        body:not(.dark-theme).qcm-workspace-active .wrong,
        body:not(.dark-theme).qcm-workspace-active .answer-item.wrong,
        body:not(.dark-theme).qcm-workspace-active .question-stats-pill.danger,
        body:not(.dark-theme).qcm-workspace-active .question-day-chip.wrong-only {
            background: #ffffff !important;
            background-image: none !important;
            box-shadow: 0 0 0 1px rgba(248, 113, 113, 0.08) !important;
        }

        body:not(.dark-theme).qcm-workspace-active .wrong {
            border-color: #fca5a5 !important;
            color: #b91c1c !important;
        }

        body:not(.dark-theme).qcm-workspace-active .wrong .opt-text {
            color: #b91c1c !important;
        }

        body:not(.dark-theme).qcm-workspace-active .wrong .opt-id {
            background: #ffffff !important;
            color: #b91c1c !important;
            border-color: #fecaca !important;
        }

        body:not(.dark-theme).qcm-workspace-active .answer-item.wrong,
        body:not(.dark-theme).qcm-workspace-active .question-stats-pill.danger,
        body:not(.dark-theme).qcm-workspace-active .question-day-chip.wrong-only {
            border-color: #fecaca !important;
            color: #dc2626 !important;
        }

        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-details .question-day-chip + .question-day-chip {
            border-left-color: rgba(203, 213, 225, 0.9) !important;
        }

        /* Final workspace overrides */
        body:not(.dark-theme).qcm-workspace-active .app-global-top-bar {
            background: #ffffff !important;
            background-color: #ffffff !important;
            background-image: none !important;
            border-bottom: none !important;
            box-shadow: none !important;
        }

        body.qcm-workspace-active #workspace-topbar-host,
        body.qcm-workspace-active #quiz-top-unified-card,
        body.qcm-workspace-active #workspace-topbar-row-1,
        body.qcm-workspace-active #workspace-topbar-row-2,
        body.qcm-workspace-active #workspace-topbar-row-3,
        body.qcm-workspace-active #workspace-topbar-row-4 {
            background: transparent !important;
            border: none !important;
            box-shadow: none !important;
        }

        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #quiz-timers-row .mini-timer-pill,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #quick-search-wrapper,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #desktop-quick-search-input,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pill,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-rating-pill,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-details,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-count,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-correct-total,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-wrong-total,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats #session-score-pill,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-2 .filter-badge,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-2 #qcm-control-extra-row,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-2 #quality-rating-shell,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-2 #difficulty-rating-shell,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 #qcm-control-main-row > button,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 #qcm-main-translate-host .large-translate-btn,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-ai-btn,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-verify-btn,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-todo-btn,
        body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-3 .inline-next-btn {
            background: transparent !important;
            background-image: none !important;
            border: none !important;
            box-shadow: none !important;
            backdrop-filter: none !important;
            -webkit-backdrop-filter: none !important;
        }

        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame::-webkit-scrollbar,
        body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-details::-webkit-scrollbar {
            display: none !important;
        }

        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #quiz-info-column,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #quiz-main-column,
        body:not(.dark-theme).qcm-workspace-active #sidebar-nav.test-workspace-sidebar,
        body:not(.dark-theme).qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card-wrapper,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card .question-card-body,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card #options-container,
        body:not(.dark-theme).qcm-workspace-active .question-comment-card,
        body:not(.dark-theme).qcm-workspace-active .question-comment-head,
        body:not(.dark-theme).qcm-workspace-active .question-comment-input,
        body:not(.dark-theme).qcm-workspace-active .question-comment-actions,
        body:not(.dark-theme).qcm-workspace-active .question-comment-empty,
        body:not(.dark-theme).qcm-workspace-active .question-comment-item,
        body:not(.dark-theme).qcm-workspace-active .question-comment-footer-spacer {
            background: transparent !important;
            background-image: none !important;
            border: none !important;
            border-radius: 0 !important;
            box-shadow: none !important;
            outline: none !important;
        }

        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #quiz-info-column,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #quiz-main-column,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card-wrapper,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card,
        body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card .question-card-body,
        body:not(.dark-theme).qcm-workspace-active .question-comment-card,
        body:not(.dark-theme).qcm-workspace-active #sidebar-nav.test-workspace-sidebar,
        body:not(.dark-theme).qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container {
            padding: 0 !important;
            margin: 0 !important;
        }

        body:not(.dark-theme).qcm-workspace-active .question-comment-head,
        body:not(.dark-theme).qcm-workspace-active .question-comment-actions,
        body:not(.dark-theme).qcm-workspace-active .question-comment-item,
        body:not(.dark-theme).qcm-workspace-active .question-comment-input {
            padding-left: 0 !important;
            padding-right: 0 !important;
        }

        body:not(.dark-theme).qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn,
        body:not(.dark-theme).qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn {
            background: transparent !important;
            border: none !important;
            box-shadow: none !important;
            border-radius: 0 !important;
            padding-left: 0 !important;
            padding-right: 0 !important;
        }

        /* Final enforced workspace overrides */
        html body:not(.dark-theme).qcm-workspace-active .app-global-top-bar {
            background: #ffffff !important;
            background-color: #ffffff !important;
            background-image: none !important;
            border-bottom: none !important;
            box-shadow: none !important;
        }

        html body.qcm-workspace-active #workspace-topbar-host,
        html body.qcm-workspace-active #quiz-top-unified-card,
        html body.qcm-workspace-active #workspace-topbar-row-1,
        html body.qcm-workspace-active #workspace-topbar-row-2,
        html body.qcm-workspace-active #workspace-topbar-row-3,
        html body.qcm-workspace-active #workspace-topbar-row-4 {
            background: transparent !important;
            background-image: none !important;
            border: none !important;
            box-shadow: none !important;
        }

        html body:not(.dark-theme).qcm-workspace-active #setup-section.test-workspace-active,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #quiz-info-column,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #quiz-main-column,
        html body:not(.dark-theme).qcm-workspace-active #sidebar-nav.test-workspace-sidebar,
        html body:not(.dark-theme).qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card-wrapper,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card .question-card-body,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card #options-container,
        html body:not(.dark-theme).qcm-workspace-active #auto-explanation-container,
        html body:not(.dark-theme).qcm-workspace-active #question-comment-section-root,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-card,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-head,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-input,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-actions,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-empty,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-item,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-footer-spacer {
            background: transparent !important;
            background-image: none !important;
            border: none !important;
            border-radius: 0 !important;
            box-shadow: none !important;
            outline: none !important;
        }

        html body:not(.dark-theme).qcm-workspace-active #setup-section.test-workspace-active,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #quiz-info-column,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #quiz-main-column,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card-wrapper,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card .question-card-body,
        html body:not(.dark-theme).qcm-workspace-active #sidebar-nav.test-workspace-sidebar,
        html body:not(.dark-theme).qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-card,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-head,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-input,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-actions,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-item {
            margin: 0 !important;
            padding-left: 0 !important;
            padding-right: 0 !important;
        }

        html body:not(.dark-theme).qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn,
        html body:not(.dark-theme).qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn {
            background: transparent !important;
            background-image: none !important;
            border: none !important;
            border-radius: 0 !important;
            box-shadow: none !important;
        }

        html body:not(.dark-theme).qcm-workspace-active .app-global-top-bar {
            background: #ffffff !important;
            background-color: #ffffff !important;
            background-image: none !important;
            border-bottom: none !important;
            box-shadow: none !important;
        }

        html body:not(.dark-theme).qcm-workspace-active #setup-section.test-workspace-active,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #quiz-info-column,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #quiz-main-column,
        html body:not(.dark-theme).qcm-workspace-active #sidebar-nav.test-workspace-sidebar,
        html body:not(.dark-theme).qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card-wrapper,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card .question-card-body,
        html body:not(.dark-theme).qcm-workspace-active #quiz-panel.test-workspace #question-card #options-container,
        html body:not(.dark-theme).qcm-workspace-active #auto-explanation-container,
        html body:not(.dark-theme).qcm-workspace-active #question-comment-section-root,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-card,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-head,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-input,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-actions,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-empty,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-item,
        html body:not(.dark-theme).qcm-workspace-active .question-comment-footer-spacer {
            background: transparent !important;
            background-image: none !important;
            border: none !important;
            border-radius: 0 !important;
            box-shadow: none !important;
            outline: none !important;
        }

        html body:not(.dark-theme).qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn,
        html body:not(.dark-theme).qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn {
            background: transparent !important;
            background-image: none !important;
            border: none !important;
            border-radius: 0 !important;
            box-shadow: none !important;
        }

        /* Final workspace fixes loaded after all panel overrides */
        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #desktop-quick-search-input,
        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #desktop-quick-search-input:focus,
        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #desktop-quick-search-input:active,
        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #desktop-quick-search-input::placeholder,
        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #desktop-quick-search-input::-webkit-input-placeholder,
        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #desktop-quick-search-input::-moz-placeholder,
        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #desktop-quick-search-input:-ms-input-placeholder {
            color: #183b63 !important;
            -webkit-text-fill-color: #183b63 !important;
            caret-color: #183b63 !important;
            opacity: 1 !important;
        }

        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame,
        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-days,
        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pills {
            scrollbar-color: rgba(255, 255, 255, 0.99) rgba(255, 255, 255, 0.99) !important;
        }

        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame::-webkit-scrollbar-track,
        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-days::-webkit-scrollbar-track,
        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pills::-webkit-scrollbar-track {
            background: #ffffff !important;
        }

        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame::-webkit-scrollbar-thumb,
        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-days::-webkit-scrollbar-thumb,
        html body:not(.dark-theme).qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pills::-webkit-scrollbar-thumb {
            background: #ffffff !important;
            border: 1px solid #8fbde0 !important;
            border-radius: 999px !important;
        }

        #test-summary-modal.test-summary-modal {
            z-index: 160000 !important;
            padding: clamp(12px, 2.3vh, 24px) !important;
            overflow-y: auto;
            align-items: center;
            justify-content: center;
            isolation: isolate;
        }

        #test-summary-modal.test-summary-modal .test-summary-card {
            width: min(900px, calc(100vw - 30px));
            max-height: calc(100dvh - 30px);
            margin: 0 auto;
            overflow: auto;
            transform: none !important;
            transform-origin: center center;
            border-radius: 22px;
            padding: clamp(16px, 2.3vw, 24px);
        }

        body.test-summary-open #setup-panel,
        body.test-summary-open #quiz-panel,
        body.test-summary-open #quiz-header,
        body.test-summary-open #workspace-topbar-host,
        body.test-summary-open #sidebar-nav {
            pointer-events: none !important;
        }

        @media (max-width: 768px) {
            #test-summary-modal.test-summary-modal {
                padding: 8px !important;
            }

            #test-summary-modal.test-summary-modal .test-summary-card {
                width: calc(100vw - 16px);
                max-height: calc(100dvh - 16px);
                border-radius: 16px;
                transform: none !important;
            }
        }

        #test-summary-modal.test-summary-modal .test-summary-grid {
            grid-template-columns: minmax(240px, 1fr) minmax(240px, 1fr);
            gap: 18px;
            align-items: center;
        }

        #test-summary-modal.test-summary-modal .test-summary-ring {
            width: min(220px, 44vw);
            height: min(220px, 44vw);
        }

        #test-summary-modal.test-summary-modal .test-summary-ring-inner {
            width: min(132px, 26vw);
            height: min(132px, 26vw);
            font-size: clamp(1rem, 2.1vw, 1.15rem);
        }

        #test-summary-modal.test-summary-modal .test-summary-actions {
            display: flex !important;
            flex-wrap: nowrap !important;
            align-items: center;
            justify-content: flex-start;
            gap: 7px;
            margin-top: 16px;
            overflow-x: auto;
            padding-bottom: 3px;
            scrollbar-width: thin;
        }

        #test-summary-modal.test-summary-modal .test-summary-primary,
        #test-summary-modal.test-summary-modal .test-summary-secondary,
        #test-summary-modal.test-summary-modal .test-summary-danger {
            width: auto !important;
            min-height: 34px;
            padding: 0 11px;
            border-radius: 999px;
            font-size: 0.76rem;
            font-weight: 900;
            line-height: 1;
            white-space: nowrap;
            flex: 0 0 auto;
            box-shadow: none;
        }

        @media (max-width: 768px) {
            #test-summary-modal.test-summary-modal .test-summary-grid {
                grid-template-columns: 1fr;
                gap: 12px;
            }

            #test-summary-modal.test-summary-modal .test-summary-ring {
                width: 176px;
                height: 176px;
            }

            #test-summary-modal.test-summary-modal .test-summary-ring-inner {
                width: 108px;
                height: 108px;
            }

            #test-summary-modal.test-summary-modal .test-summary-actions {
                margin-top: 12px;
                gap: 6px;
            }

            #test-summary-modal.test-summary-modal .test-summary-primary,
            #test-summary-modal.test-summary-modal .test-summary-secondary,
            #test-summary-modal.test-summary-modal .test-summary-danger {
                min-height: 32px;
                padding: 0 10px;
                font-size: 0.72rem;
            }
        }

        /* FINAL LOCK (2026-04-17): mobile topbar + modern stats scroll + comment frames */
        @media (max-width: 768px) {
            html body.qcm-workspace-active #workspace-topbar-mobile-line-1,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-2,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-4,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-5,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-6,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-7,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-8 {
                height: 0.7cm !important;
                min-height: 0.7cm !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-1 {
                align-items: center !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-1 #btn-pause-main,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-1 #quiz-timers-row,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-1 #quiz-timers-row .mini-timer-pill {
                align-self: center !important;
                margin-top: 0 !important;
                margin-bottom: 0 !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-4,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-5 {
                overflow: visible !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-4 .filter-badge,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-5 .filter-badge {
                border-top: 1.6px solid rgba(255, 255, 255, 0.82) !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-7 #btn-study-main {
                display: inline-flex !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-7 #btn-end-main {
                display: none !important;
            }
        }

        html body.qcm-workspace-active #quality-rating-shell .large-star:not(.active),
        html body.qcm-workspace-active #difficulty-rating-shell .large-star:not(.active) {
            color: #ffffff !important;
            -webkit-text-fill-color: #ffffff !important;
        }

        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-days,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pills {
            scrollbar-gutter: stable !important;
            scrollbar-width: thin !important;
            scrollbar-color: rgba(59, 130, 246, 0.9) rgba(191, 219, 254, 0.35) !important;
        }

        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame::-webkit-scrollbar,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-days::-webkit-scrollbar,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pills::-webkit-scrollbar {
            width: 8px !important;
            height: 8px !important;
        }

        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame::-webkit-scrollbar-track,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-days::-webkit-scrollbar-track,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pills::-webkit-scrollbar-track {
            background: linear-gradient(180deg, rgba(224, 242, 254, 0.9) 0%, rgba(186, 230, 253, 0.58) 100%) !important;
            border: 1px solid rgba(125, 211, 252, 0.7) !important;
            border-radius: 999px !important;
        }

        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame::-webkit-scrollbar-thumb,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-days::-webkit-scrollbar-thumb,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pills::-webkit-scrollbar-thumb {
            background: linear-gradient(180deg, #f8fbff 0%, #9ec9f1 48%, #78afe5 100%) !important;
            border: 1px solid #5f98cf !important;
            border-radius: 999px !important;
            box-shadow: 0 2px 8px rgba(37, 99, 235, 0.2) !important;
        }

        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame::-webkit-scrollbar-thumb:hover,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-days::-webkit-scrollbar-thumb:hover,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pills::-webkit-scrollbar-thumb:hover {
            background: linear-gradient(180deg, #ffffff 0%, #8ac0eb 44%, #5f9fdd 100%) !important;
        }

        html body.qcm-workspace-active .question-comment-card {
            border: 1.5px solid rgba(147, 197, 253, 0.94) !important;
            border-radius: 16px !important;
            background: linear-gradient(180deg, rgba(255, 255, 255, 0.97) 0%, rgba(243, 248, 255, 0.95) 100%) !important;
            box-shadow: 0 12px 24px rgba(59, 130, 246, 0.1) !important;
        }

        html body.qcm-workspace-active .question-comment-input {
            border: 1.5px solid rgba(147, 197, 253, 0.94) !important;
            border-radius: 14px !important;
            background: rgba(255, 255, 255, 0.98) !important;
        }

        html body.qcm-workspace-active .question-comment-item {
            border: 1.4px solid rgba(191, 219, 254, 0.95) !important;
            border-radius: 14px !important;
            background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 251, 255, 0.95) 100%) !important;
            box-shadow: 0 8px 20px rgba(148, 163, 184, 0.1) !important;
        }

        html body.dark-theme.qcm-workspace-active .question-comment-card {
            border-color: rgba(96, 165, 250, 0.44) !important;
            background: linear-gradient(180deg, rgba(15, 23, 42, 0.96) 0%, rgba(17, 24, 39, 0.96) 100%) !important;
            box-shadow: 0 14px 28px rgba(2, 6, 23, 0.38) !important;
        }

        html body.dark-theme.qcm-workspace-active .question-comment-input {
            border-color: rgba(96, 165, 250, 0.52) !important;
            background: rgba(15, 23, 42, 0.98) !important;
        }

        html body.dark-theme.qcm-workspace-active .question-comment-item {
            border-color: rgba(71, 85, 105, 0.52) !important;
            background: linear-gradient(180deg, rgba(15, 23, 42, 0.92) 0%, rgba(17, 24, 39, 0.95) 100%) !important;
        }

        #srs-block #srs-filter-day.srs-filter-select,
        body.dark-theme #srs-block #srs-filter-day.srs-filter-select {
            height: 32px !important;
            min-height: 32px !important;
            line-height: 32px !important;
            padding: 0 40px 0 12px !important;
            box-sizing: border-box !important;
            appearance: none !important;
            -webkit-appearance: none !important;
        }

        #srs-block #srs-filter-day.srs-filter-select::-webkit-date-and-time-value {
            padding: 0 !important;
            text-align: left !important;
            line-height: normal !important;
        }

        #srs-block #srs-filter-day.srs-filter-select::-webkit-calendar-picker-indicator {
            margin: 0 !important;
            cursor: pointer;
            opacity: 0.88;
        }

        @media (max-width: 768px) {
            #srs-block #srs-filter-day.srs-filter-select,
            body.dark-theme #srs-block #srs-filter-day.srs-filter-select {
                height: 30px !important;
                min-height: 30px !important;
                line-height: 30px !important;
                padding: 0 34px 0 8px !important;
            }
        }

        html body.qcm-workspace-active #question-stats,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats {
            overflow: visible !important;
        }

        html body.qcm-workspace-active #question-stats .question-stats-main-frame,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame {
            align-items: flex-start !important;
            flex-wrap: wrap !important;
            row-gap: 8px !important;
            min-height: auto !important;
            height: auto !important;
            overflow: visible !important;
            scrollbar-width: none !important;
        }

        html body.qcm-workspace-active #question-stats .question-stats-days,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-days,
        html body.qcm-workspace-active #question-stats .question-stats-pills,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pills {
            overflow: visible !important;
            scrollbar-width: none !important;
        }

        html body.qcm-workspace-active #question-stats .question-stats-main-frame::-webkit-scrollbar,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-main-frame::-webkit-scrollbar,
        html body.qcm-workspace-active #question-stats .question-stats-days::-webkit-scrollbar,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-days::-webkit-scrollbar,
        html body.qcm-workspace-active #question-stats .question-stats-pills::-webkit-scrollbar,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pills::-webkit-scrollbar {
            display: none !important;
            width: 0 !important;
            height: 0 !important;
        }

        html body.qcm-workspace-active #question-stats #révision-details,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats #révision-details {
            flex: 1 1 280px !important;
            min-width: 0 !important;
            width: auto !important;
            max-width: 100% !important;
            padding: 0 !important;
            border: none !important;
            background: transparent !important;
            box-shadow: none !important;
            color: inherit !important;
        }

        html body.qcm-workspace-active #question-stats .question-stats-pills,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-stats-pills {
            flex: 1 1 100% !important;
            flex-wrap: wrap !important;
            gap: 6px !important;
            width: auto !important;
            white-space: normal !important;
        }

        html body.qcm-workspace-active #question-stats .stats-word-accent {
            font-weight: 900 !important;
        }

        html body.qcm-workspace-active #question-stats .stats-word-accent.is-correct {
            color: #15803d !important;
        }

        html body.qcm-workspace-active #question-stats .stats-word-accent.is-wrong {
            color: #b91c1c !important;
        }

        html body.qcm-workspace-active #question-stats .question-attempts-dropdown,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-attempts-dropdown {
            position: relative;
            display: inline-flex;
            flex-direction: column;
            gap: 0;
            max-width: 100%;
        }

        html body.qcm-workspace-active #question-stats .question-attempts-toggle,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-attempts-toggle {
            display: inline-flex;
            align-items: center;
            gap: 8px;
            width: auto;
            max-width: 100%;
            padding: 0;
            border: none;
            background: transparent;
            box-shadow: none;
            cursor: pointer;
        }

        html body.qcm-workspace-active #question-stats .question-attempts-toggle.is-static,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-attempts-toggle.is-static {
            cursor: default;
        }

        html body.qcm-workspace-active #question-stats .question-attempts-toggle > .question-day-chip,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-attempts-toggle > .question-day-chip {
            margin: 0;
        }

        html body.qcm-workspace-active #question-stats .question-attempts-toggle > i,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-attempts-toggle > i {
            color: #2563eb !important;
            font-size: 11px;
            transition: transform 0.2s ease;
        }

        html body.qcm-workspace-active #question-stats .question-attempts-dropdown.is-open .question-attempts-toggle > i,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-attempts-dropdown.is-open .question-attempts-toggle > i {
            transform: rotate(180deg);
        }

        html body.qcm-workspace-active #question-stats .question-attempts-extra,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-attempts-extra {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            min-width: 24px;
            min-height: 24px;
            padding: 0 8px;
            border-radius: 999px;
            border: 1px solid #93c5fd;
            background: #eff6ff;
            color: #1d4ed8 !important;
            font-size: 10px;
            font-weight: 900;
            line-height: 1;
        }

        html body.qcm-workspace-active #question-stats .question-attempts-menu,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-attempts-menu {
            position: absolute;
            top: calc(100% + 8px);
            left: 0;
            z-index: 40;
            display: flex;
            flex-direction: column;
            gap: 6px;
            min-width: max-content;
            max-width: min(360px, calc(100vw - 32px));
            padding: 10px;
            border-radius: 16px;
            border: 1.5px solid rgba(147, 197, 253, 0.96);
            background: linear-gradient(180deg, rgba(255, 255, 255, 0.99) 0%, rgba(239, 246, 255, 0.98) 100%);
            box-shadow: 0 20px 40px rgba(37, 99, 235, 0.18);
        }

        html body.qcm-workspace-active #question-stats .question-attempts-menu[hidden],
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-attempts-menu[hidden] {
            display: none !important;
        }

        html body.qcm-workspace-active #question-stats .question-day-chip,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip {
            gap: 6px !important;
        }

        html body.qcm-workspace-active #question-stats .question-day-chip.is-menu-item,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip.is-menu-item {
            width: 100%;
            justify-content: space-between;
            flex-wrap: wrap;
            padding: 8px 10px !important;
            font-size: 10px !important;
        }

        html body.qcm-workspace-active #question-stats .question-day-chip-date,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip-date {
            font-weight: 900;
        }

        html body.qcm-workspace-active #question-stats .question-day-chip-status,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip-status {
            display: inline-flex;
            align-items: center;
            gap: 4px;
            flex-wrap: wrap;
        }

        html body.qcm-workspace-active #question-stats .question-day-chip-separator,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip-separator {
            color: rgba(100, 116, 139, 0.76) !important;
        }

        html body.qcm-workspace-active #question-stats .question-day-chip-status-word,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip-status-word {
            font-weight: 900;
        }

        html body.qcm-workspace-active #question-stats .question-day-chip-status-word.is-correct,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip-status-word.is-correct {
            color: #15803d !important;
        }

        html body.qcm-workspace-active #question-stats .question-day-chip-status-word.is-wrong,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip-status-word.is-wrong {
            color: #b91c1c !important;
        }

        html body.qcm-workspace-active #question-stats .question-day-chip-status-word.is-neutral,
        html body.qcm-workspace-active #workspace-topbar-row-1 #question-stats .question-day-chip-status-word.is-neutral {
            color: #64748b !important;
        }

        html body.qcm-workspace-active #question-card.is-result-wrong {
            border: 1.5px solid #fca5a5 !important;
            background: linear-gradient(180deg, #fff7f7 0%, #fee2e2 100%) !important;
            box-shadow: 0 18px 38px rgba(220, 38, 38, 0.12) !important;
        }

        html body.qcm-workspace-active #question-card.is-result-wrong #question-text,
        html body.qcm-workspace-active #question-card.is-result-wrong #question-text * {
            color: #7f1d1d !important;
        }

        html body.qcm-workspace-active #question-card.is-result-wrong #qcm-inline-count {
            background: #fee2e2 !important;
            border-color: #fda4af !important;
            color: #991b1b !important;
        }

        html body.qcm-workspace-active .opt-btn.wrong {
            border-color: #ef4444 !important;
            background: linear-gradient(180deg, #fee2e2 0%, #fecaca 100%) !important;
            color: #7f1d1d !important;
            box-shadow: 0 0 0 1px rgba(239, 68, 68, 0.16), 0 12px 24px rgba(239, 68, 68, 0.12) !important;
        }

        html body.qcm-workspace-active .opt-btn.wrong .opt-text,
        html body.qcm-workspace-active .opt-btn.wrong .opt-id {
            color: #7f1d1d !important;
        }

        html body.qcm-workspace-active .opt-btn.wrong .opt-id {
            background: #fecaca !important;
            border: 1px solid #fca5a5 !important;
        }

        html body.qcm-workspace-active .opt-btn.correct-wrong-split {
            border: 2px solid transparent !important;
            background:
                linear-gradient(90deg, #fff1f2 0%, #fecaca 50%, #ecfdf3 50%, #bbf7d0 100%) padding-box,
                linear-gradient(90deg, #ef4444 0%, #ef4444 50%, #16a34a 50%, #16a34a 100%) border-box !important;
            color: #14532d !important;
            box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.05), 0 12px 24px rgba(15, 23, 42, 0.08) !important;
        }

        html body.qcm-workspace-active .opt-btn.correct-wrong-split .opt-text {
            color: #14532d !important;
        }

        html body.qcm-workspace-active .opt-btn.correct-wrong-split .opt-id {
            background: linear-gradient(180deg, #fee2e2 0%, #fecaca 100%) !important;
            color: #7f1d1d !important;
            border: 1px solid #fca5a5 !important;
        }

        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong {
            border-color: #fda4af !important;
            background: linear-gradient(180deg, #fff1f2 0%, #ffe4e6 100%) !important;
            color: #881337 !important;
            box-shadow: 0 12px 22px rgba(244, 63, 94, 0.14) !important;
        }

        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-label,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-label,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-meta,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-meta,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-time,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-time,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index {
            color: #881337 !important;
        }

        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index {
            background: rgba(190, 24, 93, 0.12) !important;
            border: 1px solid rgba(244, 114, 182, 0.34) !important;
        }

        html body.dark-theme.qcm-workspace-active #question-card.is-result-wrong {
            border-color: rgba(248, 113, 113, 0.54) !important;
            background: linear-gradient(180deg, rgba(69, 10, 10, 0.94) 0%, rgba(127, 29, 29, 0.92) 100%) !important;
            box-shadow: 0 22px 44px rgba(2, 6, 23, 0.36) !important;
        }

        html body.dark-theme.qcm-workspace-active #question-card.is-result-wrong #question-text,
        html body.dark-theme.qcm-workspace-active #question-card.is-result-wrong #question-text * {
            color: #fecaca !important;
        }

        html body.dark-theme.qcm-workspace-active #question-card.is-result-wrong #qcm-inline-count {
            background: rgba(127, 29, 29, 0.56) !important;
            border-color: rgba(248, 113, 113, 0.44) !important;
            color: #fecaca !important;
        }

        html body.dark-theme.qcm-workspace-active .opt-btn.wrong {
            border-color: rgba(248, 113, 113, 0.78) !important;
            background: linear-gradient(180deg, rgba(127, 29, 29, 0.9) 0%, rgba(69, 10, 10, 0.92) 100%) !important;
            color: #fecaca !important;
            box-shadow: 0 0 0 1px rgba(248, 113, 113, 0.22), 0 14px 26px rgba(2, 6, 23, 0.28) !important;
        }

        html body.dark-theme.qcm-workspace-active .opt-btn.wrong .opt-text,
        html body.dark-theme.qcm-workspace-active .opt-btn.wrong .opt-id {
            color: #fecaca !important;
        }

        html body.dark-theme.qcm-workspace-active .opt-btn.wrong .opt-id {
            background: rgba(127, 29, 29, 0.56) !important;
            border: 1px solid rgba(248, 113, 113, 0.42) !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong {
            border-color: rgba(248, 113, 113, 0.44) !important;
            background: linear-gradient(180deg, rgba(127, 29, 29, 0.82) 0%, rgba(69, 10, 10, 0.88) 100%) !important;
            color: #fecaca !important;
            box-shadow: 0 14px 26px rgba(2, 6, 23, 0.32) !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-label,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-label,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-meta,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-meta,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-time,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-time,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index {
            color: #fecaca !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index {
            background: rgba(248, 113, 113, 0.12) !important;
            border: 1px solid rgba(248, 113, 113, 0.26) !important;
        }

        #test-summary-modal.test-summary-modal .test-summary-grid {
            grid-template-columns: 1fr !important;
            gap: 18px !important;
            align-items: start !important;
        }

        #test-summary-modal.test-summary-modal .test-summary-overview {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 16px;
            min-width: 0;
            flex-wrap: nowrap;
        }

        #test-summary-modal.test-summary-modal .test-summary-meta {
            display: flex !important;
            align-items: center;
            gap: 10px !important;
            flex: 1 1 auto;
            min-width: 0;
            margin-bottom: 0 !important;
        }

        #test-summary-modal.test-summary-modal .test-summary-meta > div {
            display: inline-flex;
            align-items: center;
            min-height: 40px;
            padding: 0 12px;
            border-radius: 999px;
            border: 1px solid rgba(203, 213, 225, 0.9);
            background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
            color: #334155;
            font-size: 0.9rem;
            font-weight: 800;
            white-space: nowrap;
        }

        #test-summary-modal.test-summary-modal .test-summary-stats.test-summary-stats-compact {
            display: flex !important;
            align-items: center;
            justify-content: flex-end;
            gap: 10px !important;
            width: auto;
            margin-top: 0;
            flex: 0 0 auto;
        }

        #test-summary-modal.test-summary-modal .test-summary-stats.test-summary-stats-compact .test-summary-stat-box {
            min-width: 132px;
            min-height: 74px;
            padding: 8px 12px !important;
            border-radius: 16px !important;
            display: grid;
            align-content: center;
            justify-items: center;
            box-shadow: 0 10px 22px rgba(109, 93, 252, 0.08);
        }

        #test-summary-modal.test-summary-modal .test-summary-stats.test-summary-stats-compact .test-summary-stat-label {
            font-size: 0.74rem !important;
            line-height: 1.2;
            font-weight: 900;
        }

        #test-summary-modal.test-summary-modal .test-summary-stats.test-summary-stats-compact .test-summary-stat-value {
            margin-top: 5px !important;
            font-size: 1.24rem !important;
            line-height: 1.05;
            letter-spacing: -0.02em;
        }

        #test-summary-modal.test-summary-modal .test-summary-breakdown {
            display: flex !important;
            align-items: center !important;
            justify-content: center !important;
            gap: 22px !important;
        }

        #test-summary-modal.test-summary-modal .test-summary-legend {
            width: auto !important;
            min-width: 0 !important;
            margin: 0 !important;
            align-self: center;
        }

        @media (max-width: 768px) {
            #test-summary-modal.test-summary-modal .test-summary-grid {
                grid-template-columns: 1fr !important;
                gap: 14px !important;
            }

            #test-summary-modal.test-summary-modal .test-summary-overview {
                grid-template-columns: 1fr !important;
                gap: 12px;
            }

            #test-summary-modal.test-summary-modal .test-summary-stats.test-summary-stats-compact {
                width: 100%;
                margin-top: 0;
                justify-self: stretch;
                grid-template-columns: repeat(2, minmax(0, 1fr));
            }

            #test-summary-modal.test-summary-modal .test-summary-stats.test-summary-stats-compact .test-summary-stat-box {
                min-height: 68px;
            }

            #test-summary-modal.test-summary-modal .test-summary-breakdown {
                flex-direction: column !important;
                gap: 12px !important;
            }
        }

        #test-summary-modal.test-summary-modal .test-summary-overview {
            display: flex !important;
            flex-direction: column !important;
            align-items: center !important;
            justify-content: center !important;
            gap: 16px !important;
            text-align: center !important;
        }

        #test-summary-modal.test-summary-modal .test-summary-meta {
            display: flex !important;
            flex-wrap: wrap !important;
            align-items: center !important;
            justify-content: center !important;
            gap: 10px !important;
            width: 100% !important;
        }

        #test-summary-modal.test-summary-modal .test-summary-stats.test-summary-stats-compact {
            display: flex !important;
            flex-wrap: wrap !important;
            align-items: stretch !important;
            justify-content: center !important;
            gap: 10px !important;
            width: 100% !important;
            margin-top: 0 !important;
        }

        #test-summary-modal.test-summary-modal .test-summary-breakdown {
            display: flex !important;
            flex-wrap: wrap !important;
            align-items: center !important;
            justify-content: center !important;
            gap: 22px !important;
            width: 100% !important;
            text-align: center !important;
        }

        #test-summary-modal.test-summary-modal .test-summary-legend {
            display: grid !important;
            justify-items: center !important;
            width: auto !important;
            margin: 0 auto !important;
        }

        @media (max-width: 768px) {
            #test-summary-modal.test-summary-modal .test-summary-overview,
            #test-summary-modal.test-summary-modal .test-summary-meta,
            #test-summary-modal.test-summary-modal .test-summary-stats.test-summary-stats-compact,
            #test-summary-modal.test-summary-modal .test-summary-breakdown {
                justify-content: center !important;
                align-items: center !important;
            }
        }

        #test-summary-modal.test-summary-modal .test-summary-breakdown {
            flex-direction: column !important;
            justify-content: center !important;
            align-items: center !important;
            gap: 16px !important;
        }

        #test-summary-modal.test-summary-modal .test-summary-ring {
            width: 178px !important;
            height: 178px !important;
            margin: 0 auto !important;
        }

        #test-summary-modal.test-summary-modal .test-summary-ring-inner {
            width: 112px !important;
            height: 112px !important;
            margin: 0 auto !important;
            font-size: 1.15rem !important;
        }

        #test-summary-modal.test-summary-modal .test-summary-legend {
            justify-items: center !important;
            text-align: center !important;
        }

        #test-summary-modal.test-summary-modal .test-summary-actions {
            display: flex !important;
            flex-wrap: wrap !important;
            justify-content: center !important;
            align-items: center !important;
            gap: 12px !important;
            width: 100% !important;
            margin-top: 18px !important;
            text-align: center !important;
        }

        #test-summary-modal.test-summary-modal .test-summary-primary,
        #test-summary-modal.test-summary-modal .test-summary-secondary,
        #test-summary-modal.test-summary-modal .test-summary-danger {
            width: auto !important;
            min-width: 170px !important;
            min-height: 50px !important;
            padding: 0 20px !important;
        }

        @media (max-width: 768px) {
            #test-summary-modal.test-summary-modal .test-summary-ring {
                width: 156px !important;
                height: 156px !important;
            }

            #test-summary-modal.test-summary-modal .test-summary-ring-inner {
                width: 96px !important;
                height: 96px !important;
                font-size: 1.02rem !important;
            }

            #test-summary-modal.test-summary-modal .test-summary-actions {
                gap: 10px !important;
            }

            #test-summary-modal.test-summary-modal .test-summary-primary,
            #test-summary-modal.test-summary-modal .test-summary-secondary,
            #test-summary-modal.test-summary-modal .test-summary-danger {
                min-width: 148px !important;
                min-height: 46px !important;
                padding: 0 16px !important;
            }
        }

        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-current.is-wrong,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-current.is-wrong,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong {
            border-top: none !important;
            border-right: none !important;
            border-bottom: none !important;
            border-left: 3px solid #ef4444 !important;
            border-radius: 0 !important;
            background: linear-gradient(180deg, #fef2f2 0%, #fee2e2 100%) !important;
            color: #b91c1c !important;
            box-shadow: none !important;
        }

        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-current.is-wrong *,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-current.is-wrong *,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong *,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong * {
            color: #b91c1c !important;
        }

        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-current.is-wrong .nav-instruction-index,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-current.is-wrong .nav-instruction-index,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index {
            background: rgba(255, 255, 255, 0.9) !important;
            border: 1px solid rgba(248, 113, 113, 0.18) !important;
            color: #b91c1c !important;
        }

        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-current.is-wrong .nav-instruction-time,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-current.is-wrong .nav-instruction-time,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-time,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-time {
            color: #9f1239 !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-current.is-wrong,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-current.is-wrong,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong {
            border-top: none !important;
            border-right: none !important;
            border-bottom: none !important;
            border-left: 3px solid rgba(248, 113, 113, 0.74) !important;
            border-radius: 0 !important;
            background: linear-gradient(180deg, rgba(127, 29, 29, 0.26) 0%, rgba(69, 10, 10, 0.2) 100%) !important;
            color: #fecaca !important;
            box-shadow: none !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-current.is-wrong *,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-current.is-wrong *,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong *,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong * {
            color: #fecaca !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-current.is-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-current.is-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index {
            background: rgba(255, 255, 255, 0.08) !important;
            border: 1px solid rgba(248, 113, 113, 0.24) !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-current.is-wrong .nav-instruction-time,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-current.is-wrong .nav-instruction-time,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-time,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-time {
            color: #fda4af !important;
        }

        html body.qcm-workspace-active #question-card.is-result-wrong #question-text,
        html body.qcm-workspace-active #question-card.is-result-wrong #question-text * {
            color: #0f172a !important;
        }

        html body.qcm-workspace-active #question-card.is-result-wrong #qcm-inline-count {
            background: #eff6ff !important;
            border-color: #bfdbfe !important;
            color: #2563eb !important;
        }

        html body.dark-theme.qcm-workspace-active #question-card.is-result-wrong #question-text,
        html body.dark-theme.qcm-workspace-active #question-card.is-result-wrong #question-text * {
            color: #e5eefc !important;
        }

        html body.dark-theme.qcm-workspace-active #question-card.is-result-wrong #qcm-inline-count {
            background: rgba(37, 99, 235, 0.16) !important;
            border-color: rgba(96, 165, 250, 0.34) !important;
            color: #93c5fd !important;
        }

        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result="wrong"],
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result="wrong"] {
            border-top: none !important;
            border-right: none !important;
            border-bottom: none !important;
            border-left: 3px solid #ef4444 !important;
            border-radius: 0 !important;
            background: linear-gradient(180deg, #fff5f5 0%, #ffe4e6 100%) !important;
            color: #b42318 !important;
            box-shadow: none !important;
        }

        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-label,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-label,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-label,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-label,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-meta,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-meta,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-meta,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-meta,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-time,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-time,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-time,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-time,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-index,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-index,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-index,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-index {
            color: #b42318 !important;
        }

        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-index,
        html body.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-index,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-index,
        html body.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-index {
            background: rgba(255, 255, 255, 0.9) !important;
            border: 1px solid rgba(239, 68, 68, 0.18) !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result="wrong"],
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result="wrong"] {
            border-top: none !important;
            border-right: none !important;
            border-bottom: none !important;
            border-left: 3px solid rgba(248, 113, 113, 0.74) !important;
            border-radius: 0 !important;
            background: linear-gradient(180deg, rgba(127, 29, 29, 0.28) 0%, rgba(69, 10, 10, 0.22) 100%) !important;
            color: #fecaca !important;
            box-shadow: none !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-label,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-label,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-label,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-label,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-meta,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-meta,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-meta,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-meta,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-time,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-time,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-time,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-time,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-index {
            color: #fecaca !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-index {
            background: rgba(255, 255, 255, 0.08) !important;
            border: 1px solid rgba(248, 113, 113, 0.24) !important;
        }

        #trash-list-block {
            position: fixed;
            inset: 0;
            background: #fff5f5;
            z-index: 9999;
            display: none;
            overflow: hidden;
            flex-direction: column;
        }

        #trash-list-block.active {
            display: flex;
        }

        .app-sidebar-link-trash {
            background: transparent;
        }

        #trash-list-block .todo-list-header {
            background: linear-gradient(135deg, #b91c1c 0%, #dc2626 100%);
            box-shadow: 0 10px 24px rgba(220, 38, 38, 0.22);
        }

        #trash-list-block .todo-list-toolbar {
            background: linear-gradient(135deg, #fff7f7 0%, #fff1f2 100%);
            border-bottom-color: #fecdd3;
        }

        #trash-list-block .todo-filter-select:focus {
            border-color: #fca5a5;
            box-shadow: 0 0 0 3px rgba(248, 113, 113, 0.18);
        }

        #trash-list-block .trash-list-checkbox {
            accent-color: #dc2626;
        }

        #trash-list-block .trash-list-test-btn {
            border-color: #fecaca;
            background: #fff1f2;
            color: #b91c1c;
        }

        #trash-list-block .trash-list-test-btn:hover {
            background: #ffe4e6;
            border-color: #f87171;
        }

        .question-trash-action-row {
            margin-top: 12px;
        }

        .question-comment-trash-btn {
            width: 100%;
            min-height: 38px;
            border-radius: 14px;
            border: 1.5px solid #fecaca;
            background: linear-gradient(135deg, #fff1f2 0%, #ffe4e6 100%);
            color: #b91c1c;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            font-size: 12px;
            font-weight: 900;
            cursor: pointer;
            transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
        }

        .question-comment-trash-btn:hover,
        .question-comment-trash-btn:focus-visible {
            transform: translateY(-1px);
            border-color: #f87171;
            background: linear-gradient(135deg, #ffe4e6 0%, #fecdd3 100%);
        }

        .question-comment-trash-btn.is-added {
            border-color: #f87171;
            background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
            color: #991b1b;
        }

        body.dark-theme #trash-list-block {
            background: linear-gradient(180deg, #1f0b10 0%, #111827 100%) !important;
            color: #fecaca !important;
        }

        body.dark-theme #trash-list-block .todo-list-header {
            background: linear-gradient(135deg, #7f1d1d 0%, #991b1b 100%) !important;
            box-shadow: 0 12px 28px rgba(2, 6, 23, 0.34) !important;
        }

        body.dark-theme #trash-list-block .todo-list-count,
        body.dark-theme #trash-list-block .todo-list-close {
            background: rgba(69, 10, 10, 0.42) !important;
            border-color: rgba(248, 113, 113, 0.24) !important;
            color: #fecaca !important;
        }

        body.dark-theme #trash-list-block .todo-list-toolbar {
            background: linear-gradient(180deg, #200d14 0%, #25121a 100%) !important;
            border-bottom-color: rgba(248, 113, 113, 0.18) !important;
        }

        body.dark-theme #trash-list-block .todo-filter-select,
        body.dark-theme #trash-list-block .todo-list-item,
        body.dark-theme #trash-list-block .todo-list-item.is-done,
        body.dark-theme #trash-list-block .todo-list-chip,
        body.dark-theme #trash-list-block .trash-list-test-btn {
            background: #25121a !important;
            color: #fecaca !important;
            border-color: rgba(248, 113, 113, 0.22) !important;
            box-shadow: none !important;
        }

        body.dark-theme #trash-list-block .todo-list-item {
            background: linear-gradient(180deg, #200d14 0%, #25121a 100%) !important;
            box-shadow: 0 12px 24px rgba(2, 6, 23, 0.24) !important;
        }

        body.dark-theme #trash-list-block .todo-list-item.is-done {
            background: linear-gradient(180deg, #22161b 0%, #2b1b22 100%) !important;
        }

        body.dark-theme #trash-list-block .todo-list-title,
        body.dark-theme #trash-list-block .todo-list-empty,
        body.dark-theme #trash-list-block .todo-list-empty i {
            color: #fecaca !important;
        }

        body.dark-theme #trash-list-block .todo-list-item.is-done .todo-list-title {
            color: #fda4af !important;
        }

        body.dark-theme #trash-list-block .trash-list-test-btn {
            background: rgba(127, 29, 29, 0.46) !important;
            color: #fecaca !important;
            border-color: rgba(248, 113, 113, 0.28) !important;
        }

        body.dark-theme .question-comment-trash-btn {
            border-color: rgba(248, 113, 113, 0.3) !important;
            background: linear-gradient(135deg, rgba(127, 29, 29, 0.44) 0%, rgba(69, 10, 10, 0.4) 100%) !important;
            color: #fecaca !important;
        }

        body.dark-theme .question-comment-trash-btn:hover,
        body.dark-theme .question-comment-trash-btn:focus-visible,
        body.dark-theme .question-comment-trash-btn.is-added {
            border-color: rgba(248, 113, 113, 0.44) !important;
            background: linear-gradient(135deg, rgba(153, 27, 27, 0.54) 0%, rgba(127, 29, 29, 0.5) 100%) !important;
            color: #fee2e2 !important;
        }

        @media (max-width: 768px) {
            html body.qcm-workspace-active #workspace-topbar-mobile-line-8 {
                display: flex !important;
                align-items: center !important;
                justify-content: center !important;
                min-height: 0.76cm !important;
                height: auto !important;
                gap: 0 !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-8 #qcm-main-translate-host {
                display: none !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-8 #qcm-inline-actions-host {
                width: 100% !important;
                display: flex !important;
                align-items: center !important;
                justify-content: center !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-8 #qcm-inline-actions-host .question-actions-after-options {
                width: 100% !important;
                display: flex !important;
                align-items: center !important;
                justify-content: center !important;
                gap: 8px !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-8 #qcm-inline-actions-host .inline-ai-btn,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-8 #qcm-inline-actions-host .inline-todo-btn,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-8 #qcm-inline-actions-host .inline-end-btn {
                display: none !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-8 #qcm-inline-actions-host .inline-verify-btn,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-8 #qcm-inline-actions-host .inline-next-btn {
                display: inline-flex !important;
                align-items: center !important;
                justify-content: center !important;
                min-width: 92px !important;
            }
        }

        #srs-start-btn {
            display: none !important;
        }

        /* Final QCM workspace tone + press feedback overrides */
        html body.qcm-workspace-active {
            --workspace-topbar-press-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.1), 0 6px 14px rgba(148, 163, 184, 0.14);
            --workspace-topbar-press-filter: brightness(0.9) saturate(0.96);
        }

        html body.qcm-workspace-active #question-filters-bar .filter-badge,
        html body.qcm-workspace-active #btn-mindmap-main,
        html body.qcm-workspace-active #quality-rating-shell,
        html body.qcm-workspace-active #difficulty-rating-shell,
        html body.qcm-workspace-active #qcm-control-main-row > button,
        html body.qcm-workspace-active #qcm-main-translate-host .large-translate-btn,
        html body.qcm-workspace-active .inline-ai-btn,
        html body.qcm-workspace-active .inline-end-btn,
        html body.qcm-workspace-active .inline-verify-btn,
        html body.qcm-workspace-active .inline-todo-btn,
        html body.qcm-workspace-active .inline-next-btn {
            transition: background-color 0.16s ease, border-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease, transform 0.12s ease !important;
        }

        html body.qcm-workspace-active #question-filters-bar .filter-badge.filter-faculty {
            --workspace-tile-bg: #f8fafc;
            --workspace-tile-border: #cbd5e1;
            --workspace-tile-text: #475569;
            --workspace-tile-bg-active: #eef2f7;
            --workspace-tile-border-active: #b8c4d4;
            --workspace-tile-text-active: #334155;
            --workspace-tile-shadow: 0 8px 18px rgba(148, 163, 184, 0.13);
        }

        html body.qcm-workspace-active #question-filters-bar .filter-badge.filter-rotation {
            --workspace-tile-bg: #ecfeff;
            --workspace-tile-border: #a5f3fc;
            --workspace-tile-text: #0f766e;
            --workspace-tile-bg-active: #dff7f8;
            --workspace-tile-border-active: #7dd3d8;
            --workspace-tile-text-active: #0f5f59;
            --workspace-tile-shadow: 0 8px 18px rgba(115, 173, 179, 0.13);
        }

        html body.qcm-workspace-active #question-filters-bar .filter-badge.filter-year {
            --workspace-tile-bg: #eff6ff;
            --workspace-tile-border: #bfdbfe;
            --workspace-tile-text: #1d4ed8;
            --workspace-tile-bg-active: #dbeafe;
            --workspace-tile-border-active: #93c5fd;
            --workspace-tile-text-active: #1e40af;
            --workspace-tile-shadow: 0 8px 18px rgba(107, 133, 194, 0.13);
        }

        html body.qcm-workspace-active #question-filters-bar .filter-badge.filter-module {
            --workspace-tile-bg: #fff7ed;
            --workspace-tile-border: #fed7aa;
            --workspace-tile-text: #c2410c;
            --workspace-tile-bg-active: #ffedd5;
            --workspace-tile-border-active: #fdba74;
            --workspace-tile-text-active: #9a3412;
            --workspace-tile-shadow: 0 8px 18px rgba(191, 127, 114, 0.11);
        }

        html body.qcm-workspace-active #question-filters-bar .filter-badge.filter-lesson {
            --workspace-tile-bg: #f5f3ff;
            --workspace-tile-border: #ddd6fe;
            --workspace-tile-text: #6d28d9;
            --workspace-tile-bg-active: #ede9fe;
            --workspace-tile-border-active: #c4b5fd;
            --workspace-tile-text-active: #5b21b6;
            --workspace-tile-shadow: 0 8px 18px rgba(132, 116, 190, 0.11);
        }

        html body.qcm-workspace-active #btn-prev-main {
            --workspace-tile-bg: #f8fafc;
            --workspace-tile-border: #cbd5e1;
            --workspace-tile-text: #334155;
            --workspace-tile-bg-active: #eef2f7;
            --workspace-tile-border-active: #b8c4d4;
            --workspace-tile-text-active: #1e293b;
            --workspace-tile-shadow: 0 8px 18px rgba(148, 163, 184, 0.13);
        }

        html body.qcm-workspace-active #btn-study-main,
        html body.qcm-workspace-active .inline-verify-btn {
            --workspace-tile-bg: #ecfdf3;
            --workspace-tile-border: #bbf7d0;
            --workspace-tile-text: #15803d;
            --workspace-tile-bg-active: #dcfce7;
            --workspace-tile-border-active: #86efac;
            --workspace-tile-text-active: #166534;
            --workspace-tile-shadow: 0 8px 18px rgba(111, 165, 140, 0.13);
        }

        html body.qcm-workspace-active #btn-notes-main,
        html body.qcm-workspace-active .inline-todo-btn {
            --workspace-tile-bg: #fff7ed;
            --workspace-tile-border: #fed7aa;
            --workspace-tile-text: #c2410c;
            --workspace-tile-bg-active: #ffedd5;
            --workspace-tile-border-active: #fdba74;
            --workspace-tile-text-active: #9a3412;
            --workspace-tile-shadow: 0 8px 18px rgba(188, 143, 112, 0.11);
        }

        html body.qcm-workspace-active #btn-close-companion-main,
        html body.qcm-workspace-active #btn-end-main,
        html body.qcm-workspace-active .inline-end-btn {
            --workspace-tile-bg: #fdf4f7;
            --workspace-tile-border: #edd8de;
            --workspace-tile-text: #b66674;
            --workspace-tile-bg-active: #f1e0e5;
            --workspace-tile-border-active: #dfc2ca;
            --workspace-tile-text-active: #95505d;
            --workspace-tile-shadow: 0 8px 18px rgba(191, 124, 139, 0.12);
            background-image: none !important;
        }

        html body.qcm-workspace-active .inline-end-btn,
        html body.qcm-workspace-active .inline-end-btn:hover,
        html body.qcm-workspace-active .inline-end-btn:focus-visible {
            background: var(--workspace-tile-bg, #fdf4f5) !important;
            background-color: var(--workspace-tile-bg, #fdf4f5) !important;
            background-image: none !important;
            border: 1px solid var(--workspace-tile-border, #f3d1d7) !important;
            color: var(--workspace-tile-text, #b75260) !important;
            box-shadow: 0 8px 18px rgba(183, 82, 96, 0.12) !important;
        }

        html body.qcm-workspace-active .inline-end-btn * {
            color: inherit !important;
        }

        html body.qcm-workspace-active #btn-explain-main {
            --workspace-tile-bg: #eef2ff;
            --workspace-tile-border: #c7d2fe;
            --workspace-tile-text: #4338ca;
            --workspace-tile-bg-active: #e0e7ff;
            --workspace-tile-border-active: #a5b4fc;
            --workspace-tile-text-active: #3730a3;
            --workspace-tile-shadow: 0 8px 18px rgba(132, 116, 190, 0.11);
        }

        html body.qcm-workspace-active #btn-schema-main,
        html body.qcm-workspace-active #btn-mindmap-main,
        html body.qcm-workspace-active .inline-next-btn {
            --workspace-tile-bg: #ecfeff;
            --workspace-tile-border: #a5f3fc;
            --workspace-tile-text: #0f766e;
            --workspace-tile-bg-active: #dff7f8;
            --workspace-tile-border-active: #7dd3d8;
            --workspace-tile-text-active: #115e59;
            --workspace-tile-shadow: 0 8px 18px rgba(115, 173, 179, 0.13);
        }

        html body.qcm-workspace-active #qcm-main-translate-host .large-translate-btn,
        html body.qcm-workspace-active .inline-ai-btn:not(.is-detailed) {
            --workspace-tile-bg: #eff6ff;
            --workspace-tile-border: #bfdbfe;
            --workspace-tile-text: #1d4ed8;
            --workspace-tile-bg-active: #dbeafe;
            --workspace-tile-border-active: #93c5fd;
            --workspace-tile-text-active: #1e40af;
            --workspace-tile-shadow: 0 8px 18px rgba(107, 133, 194, 0.12);
        }

        html body.qcm-workspace-active .inline-ai-btn.is-detailed {
            --workspace-tile-bg: #f5f3ff;
            --workspace-tile-border: #ddd6fe;
            --workspace-tile-text: #6d28d9;
            --workspace-tile-bg-active: #ede9fe;
            --workspace-tile-border-active: #c4b5fd;
            --workspace-tile-text-active: #5b21b6;
            --workspace-tile-shadow: 0 8px 18px rgba(132, 116, 190, 0.11);
        }

        html body.qcm-workspace-active #quality-rating-shell {
            --workspace-tile-bg: #ecfeff;
            --workspace-tile-border: #a5f3fc;
            --workspace-tile-text: #0f766e;
            --workspace-tile-bg-active: #dff7f8;
            --workspace-tile-border-active: #7dd3d8;
            --workspace-tile-text-active: #115e59;
            --workspace-tile-shadow: 0 8px 18px rgba(115, 173, 179, 0.13);
        }

        html body.qcm-workspace-active #difficulty-rating-shell {
            --workspace-tile-bg: #fff7ed;
            --workspace-tile-border: #fed7aa;
            --workspace-tile-text: #c2410c;
            --workspace-tile-bg-active: #ffedd5;
            --workspace-tile-border-active: #fdba74;
            --workspace-tile-text-active: #9a3412;
            --workspace-tile-shadow: 0 8px 18px rgba(188, 143, 112, 0.11);
        }

        html body.dark-theme.qcm-workspace-active #quick-search-wrapper {
            --workspace-tile-bg: linear-gradient(180deg, #111827 0%, #0f172a 100%);
            --workspace-tile-border: rgba(96, 165, 250, 0.22);
            --workspace-tile-text: #e2e8f0;
            --workspace-tile-bg-active: #1a2740;
            --workspace-tile-border-active: rgba(125, 211, 252, 0.34);
            --workspace-tile-text-active: #ffffff;
            --workspace-tile-shadow: 0 14px 26px rgba(2, 6, 23, 0.34);
        }

        html body.dark-theme.qcm-workspace-active #question-stats {
            --workspace-tile-bg: linear-gradient(180deg, #162033 0%, #0f172a 100%);
            --workspace-tile-border: rgba(96, 165, 250, 0.22);
            --workspace-tile-text: #e2e8f0;
            --workspace-tile-bg-active: #1d2b44;
            --workspace-tile-border-active: rgba(125, 211, 252, 0.32);
            --workspace-tile-text-active: #ffffff;
            --workspace-tile-shadow: 0 14px 28px rgba(2, 6, 23, 0.34);
        }

        html body.dark-theme.qcm-workspace-active #question-filters-bar .filter-badge.filter-faculty {
            --workspace-tile-bg: linear-gradient(180deg, #1f2937 0%, #111827 100%);
            --workspace-tile-border: rgba(148, 163, 184, 0.18);
            --workspace-tile-text: #d1d9e6;
            --workspace-tile-bg-active: #273345;
            --workspace-tile-border-active: rgba(148, 163, 184, 0.28);
            --workspace-tile-text-active: #ffffff;
            --workspace-tile-shadow: 0 12px 24px rgba(2, 6, 23, 0.26);
        }

        html body.dark-theme.qcm-workspace-active #question-filters-bar .filter-badge.filter-rotation {
            --workspace-tile-bg: linear-gradient(180deg, rgba(8, 78, 73, 0.78) 0%, rgba(15, 118, 110, 0.36) 100%);
            --workspace-tile-border: rgba(45, 212, 191, 0.22);
            --workspace-tile-text: #ccfbf1;
            --workspace-tile-bg-active: rgba(10, 94, 88, 0.84);
            --workspace-tile-border-active: rgba(94, 234, 212, 0.3);
            --workspace-tile-text-active: #f0fdfa;
            --workspace-tile-shadow: 0 12px 24px rgba(2, 6, 23, 0.26);
        }

        html body.dark-theme.qcm-workspace-active #question-filters-bar .filter-badge.filter-year {
            --workspace-tile-bg: linear-gradient(180deg, rgba(30, 64, 175, 0.68) 0%, rgba(30, 41, 59, 0.96) 100%);
            --workspace-tile-border: rgba(96, 165, 250, 0.24);
            --workspace-tile-text: #dbeafe;
            --workspace-tile-bg-active: rgba(37, 99, 235, 0.3);
            --workspace-tile-border-active: rgba(125, 211, 252, 0.32);
            --workspace-tile-text-active: #eff6ff;
            --workspace-tile-shadow: 0 12px 24px rgba(2, 6, 23, 0.26);
        }

        html body.dark-theme.qcm-workspace-active #question-filters-bar .filter-badge.filter-module,
        html body.dark-theme.qcm-workspace-active #btn-notes-main,
        html body.dark-theme.qcm-workspace-active .inline-todo-btn,
        html body.dark-theme.qcm-workspace-active #difficulty-rating-shell {
            --workspace-tile-bg: linear-gradient(180deg, rgba(120, 53, 15, 0.72) 0%, rgba(41, 37, 36, 0.98) 100%);
            --workspace-tile-border: rgba(251, 191, 36, 0.18);
            --workspace-tile-text: #fde68a;
            --workspace-tile-bg-active: rgba(146, 64, 14, 0.82);
            --workspace-tile-border-active: rgba(252, 211, 77, 0.28);
            --workspace-tile-text-active: #fef3c7;
            --workspace-tile-shadow: 0 12px 24px rgba(2, 6, 23, 0.26);
        }

        html body.dark-theme.qcm-workspace-active #question-filters-bar .filter-badge.filter-lesson,
        html body.dark-theme.qcm-workspace-active #btn-explain-main,
        html body.dark-theme.qcm-workspace-active .inline-ai-btn.is-detailed {
            --workspace-tile-bg: linear-gradient(180deg, rgba(67, 56, 202, 0.52) 0%, rgba(30, 41, 59, 0.96) 100%);
            --workspace-tile-border: rgba(129, 140, 248, 0.22);
            --workspace-tile-text: #ddd6fe;
            --workspace-tile-bg-active: rgba(79, 70, 229, 0.34);
            --workspace-tile-border-active: rgba(165, 180, 252, 0.32);
            --workspace-tile-text-active: #f5f3ff;
            --workspace-tile-shadow: 0 12px 24px rgba(2, 6, 23, 0.26);
        }

        html body.dark-theme.qcm-workspace-active #btn-prev-main,
        html body.dark-theme.qcm-workspace-active #qcm-main-translate-host .large-translate-btn,
        html body.dark-theme.qcm-workspace-active .inline-ai-btn:not(.is-detailed) {
            --workspace-tile-bg: linear-gradient(180deg, rgba(30, 64, 175, 0.52) 0%, rgba(15, 23, 42, 0.98) 100%);
            --workspace-tile-border: rgba(96, 165, 250, 0.22);
            --workspace-tile-text: #dbeafe;
            --workspace-tile-bg-active: rgba(37, 99, 235, 0.32);
            --workspace-tile-border-active: rgba(125, 211, 252, 0.32);
            --workspace-tile-text-active: #eff6ff;
            --workspace-tile-shadow: 0 12px 24px rgba(2, 6, 23, 0.26);
        }

        html body.dark-theme.qcm-workspace-active #btn-study-main,
        html body.dark-theme.qcm-workspace-active .inline-verify-btn {
            --workspace-tile-bg: linear-gradient(180deg, rgba(21, 128, 61, 0.56) 0%, rgba(15, 23, 42, 0.98) 100%);
            --workspace-tile-border: rgba(74, 222, 128, 0.22);
            --workspace-tile-text: #dcfce7;
            --workspace-tile-bg-active: rgba(22, 163, 74, 0.34);
            --workspace-tile-border-active: rgba(134, 239, 172, 0.3);
            --workspace-tile-text-active: #f0fdf4;
            --workspace-tile-shadow: 0 12px 24px rgba(2, 6, 23, 0.26);
        }

        html body.dark-theme.qcm-workspace-active #btn-schema-main,
        html body.dark-theme.qcm-workspace-active #btn-mindmap-main,
        html body.dark-theme.qcm-workspace-active #quality-rating-shell,
        html body.dark-theme.qcm-workspace-active .inline-next-btn {
            --workspace-tile-bg: linear-gradient(180deg, rgba(8, 78, 73, 0.76) 0%, rgba(15, 23, 42, 0.98) 100%);
            --workspace-tile-border: rgba(45, 212, 191, 0.22);
            --workspace-tile-text: #ccfbf1;
            --workspace-tile-bg-active: rgba(13, 148, 136, 0.3);
            --workspace-tile-border-active: rgba(94, 234, 212, 0.3);
            --workspace-tile-text-active: #ecfeff;
            --workspace-tile-shadow: 0 12px 24px rgba(2, 6, 23, 0.26);
        }

        html body.dark-theme.qcm-workspace-active #btn-close-companion-main,
        html body.dark-theme.qcm-workspace-active #btn-end-main,
        html body.dark-theme.qcm-workspace-active .inline-end-btn {
            --workspace-tile-bg: linear-gradient(180deg, rgba(153, 27, 27, 0.62) 0%, rgba(30, 41, 59, 0.96) 100%);
            --workspace-tile-border: rgba(248, 113, 113, 0.22);
            --workspace-tile-text: #fecaca;
            --workspace-tile-bg-active: rgba(185, 28, 28, 0.38);
            --workspace-tile-border-active: rgba(252, 165, 165, 0.3);
            --workspace-tile-text-active: #fee2e2;
            --workspace-tile-shadow: 0 12px 24px rgba(2, 6, 23, 0.26);
        }

        html body.qcm-workspace-active #question-filters-bar .filter-badge:active,
        html body.qcm-workspace-active #question-filters-bar .filter-badge.is-pressing,
        html body.qcm-workspace-active #btn-mindmap-main:active,
        html body.qcm-workspace-active #btn-mindmap-main.is-pressing,
        html body.qcm-workspace-active #quality-rating-shell:active,
        html body.qcm-workspace-active #quality-rating-shell.is-pressing,
        html body.qcm-workspace-active #difficulty-rating-shell:active,
        html body.qcm-workspace-active #difficulty-rating-shell.is-pressing,
        html body.qcm-workspace-active #qcm-control-main-row > button:active,
        html body.qcm-workspace-active #qcm-control-main-row > button.is-pressing,
        html body.qcm-workspace-active #qcm-main-translate-host .large-translate-btn:active,
        html body.qcm-workspace-active #qcm-main-translate-host .large-translate-btn.is-pressing,
        html body.qcm-workspace-active .inline-ai-btn:active,
        html body.qcm-workspace-active .inline-ai-btn.is-pressing,
        html body.qcm-workspace-active .inline-end-btn:active,
        html body.qcm-workspace-active .inline-end-btn.is-pressing,
        html body.qcm-workspace-active .inline-verify-btn:active,
        html body.qcm-workspace-active .inline-verify-btn.is-pressing,
        html body.qcm-workspace-active .inline-todo-btn:active,
        html body.qcm-workspace-active .inline-todo-btn.is-pressing,
        html body.qcm-workspace-active .inline-next-btn:active,
        html body.qcm-workspace-active .inline-next-btn.is-pressing {
            background: var(--workspace-tile-bg-active, var(--workspace-tile-bg, #ffffff)) !important;
            background-color: var(--workspace-tile-bg-active, var(--workspace-tile-bg, #ffffff)) !important;
            border-color: var(--workspace-tile-border-active, var(--workspace-tile-border, #d8e3f0)) !important;
            color: var(--workspace-tile-text-active, var(--workspace-tile-text, #0f172a)) !important;
            box-shadow: var(--workspace-topbar-press-shadow) !important;
            filter: var(--workspace-topbar-press-filter) !important;
            transform: translateY(1px) scale(0.985) !important;
        }

        html body.qcm-workspace-active #question-filters-bar .filter-badge:active *,
        html body.qcm-workspace-active #question-filters-bar .filter-badge.is-pressing *,
        html body.qcm-workspace-active #btn-mindmap-main:active *,
        html body.qcm-workspace-active #btn-mindmap-main.is-pressing *,
        html body.qcm-workspace-active #quality-rating-shell:active *,
        html body.qcm-workspace-active #quality-rating-shell.is-pressing *,
        html body.qcm-workspace-active #difficulty-rating-shell:active *,
        html body.qcm-workspace-active #difficulty-rating-shell.is-pressing *,
        html body.qcm-workspace-active #qcm-control-main-row > button:active *,
        html body.qcm-workspace-active #qcm-control-main-row > button.is-pressing *,
        html body.qcm-workspace-active #qcm-main-translate-host .large-translate-btn:active *,
        html body.qcm-workspace-active #qcm-main-translate-host .large-translate-btn.is-pressing *,
        html body.qcm-workspace-active .inline-ai-btn:active *,
        html body.qcm-workspace-active .inline-ai-btn.is-pressing *,
        html body.qcm-workspace-active .inline-end-btn:active *,
        html body.qcm-workspace-active .inline-end-btn.is-pressing *,
        html body.qcm-workspace-active .inline-verify-btn:active *,
        html body.qcm-workspace-active .inline-verify-btn.is-pressing *,
        html body.qcm-workspace-active .inline-todo-btn:active *,
        html body.qcm-workspace-active .inline-todo-btn.is-pressing *,
        html body.qcm-workspace-active .inline-next-btn:active *,
        html body.qcm-workspace-active .inline-next-btn.is-pressing * {
            color: inherit !important;
        }

        html body.dark-theme.qcm-workspace-active #desktop-quick-search-input,
        html body.dark-theme.qcm-workspace-active #desktop-quick-search-input:focus,
        html body.dark-theme.qcm-workspace-active #desktop-quick-search-input:active {
            color: #e2e8f0 !important;
            -webkit-text-fill-color: #e2e8f0 !important;
            caret-color: #93c5fd !important;
        }

        html body.dark-theme.qcm-workspace-active .app-global-top-bar,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-host,
        html body.dark-theme.qcm-workspace-active #quiz-top-unified-card,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-1,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-2,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-3,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-4,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-1 #quiz-top-row,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-2 #question-filters-bar,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-3 #qcm-control-bar,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-3 #qcm-control-extra-row,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-4 #qcm-inline-actions-host,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-4 #schema-workspace-panel-host,
        html body.dark-theme.qcm-workspace-active #main-content,
        html body.dark-theme.qcm-workspace-active #setup-section.test-workspace-active,
        html body.dark-theme.qcm-workspace-active #quiz-panel.test-workspace,
        html body.dark-theme.qcm-workspace-active #quiz-main-column,
        html body.dark-theme.qcm-workspace-active #quiz-info-column {
            background-color: #0b1220 !important;
            background-image: none !important;
            color: #e5eefc !important;
        }

        html body.dark-theme.qcm-workspace-active #question-card-wrapper,
        html body.dark-theme.qcm-workspace-active #question-card,
        html body.dark-theme.qcm-workspace-active #question-card .question-card-body,
        html body.dark-theme.qcm-workspace-active #nav-items-container,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container,
        html body.dark-theme.qcm-workspace-active #study-quiz-content,
        html body.dark-theme.qcm-workspace-active #quiz-container {
            background: linear-gradient(180deg, #0f172a 0%, #111827 100%) !important;
            color: #e5eefc !important;
            border-color: rgba(148, 163, 184, 0.18) !important;
        }

        html body.dark-theme.qcm-workspace-active #main-content,
        html body.dark-theme.qcm-workspace-active #setup-section.test-workspace-active,
        html body.dark-theme.qcm-workspace-active #quiz-info-column,
        html body.dark-theme.qcm-workspace-active #question-card-wrapper,
        html body.dark-theme.qcm-workspace-active #question-card,
        html body.dark-theme.qcm-workspace-active .question-card-body,
        html body.dark-theme.qcm-workspace-active #nav-items-container,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container {
            scrollbar-color: rgba(96, 165, 250, 0.34) rgba(15, 23, 42, 0.92) !important;
        }

        html body.dark-theme.qcm-workspace-active #main-content::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active #setup-section.test-workspace-active::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active #quiz-info-column::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active #question-card-wrapper::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active #question-card::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active .question-card-body::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active #nav-items-container::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container::-webkit-scrollbar-track {
            background: rgba(15, 23, 42, 0.92) !important;
        }

        html body.dark-theme.qcm-workspace-active #main-content::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active #setup-section.test-workspace-active::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active #quiz-info-column::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active #question-card-wrapper::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active #question-card::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active .question-card-body::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active #nav-items-container::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container::-webkit-scrollbar-thumb {
            background: rgba(96, 165, 250, 0.34) !important;
            border-radius: 999px !important;
            border: 1px solid rgba(125, 211, 252, 0.18) !important;
        }

        /* ABSOLUTE FINAL LOCK (2026-04-22): keep this block at EOF */
        @media (max-width: 768px) {
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-compact-row {
                width: 100% !important;
                min-width: 0 !important;
                overflow: visible !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-compact-row,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-main-frame {
                display: flex !important;
                align-items: center !important;
                flex-wrap: nowrap !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-main-frame {
                width: 100% !important;
                max-width: 100% !important;
                min-width: 0 !important;
                justify-content: flex-start !important;
                gap: 5px !important;
                padding: 5px 10px !important;
                border: 1.5px solid #74b0df !important;
                border-radius: 999px !important;
                background: linear-gradient(180deg, #97cff8 0%, #87c2ef 100%) !important;
                box-shadow: 0 10px 22px rgba(114, 164, 215, 0.18) !important;
                overflow-x: auto !important;
                overflow-y: hidden !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats #révision-details,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-pills,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-attempts-dropdown {
                display: inline-flex !important;
                align-items: center !important;
                justify-content: center !important;
                flex: 0 0 auto !important;
                min-width: 0 !important;
                width: auto !important;
                overflow: visible !important;
                white-space: nowrap !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats #révision-details {
                order: 1 !important;
                flex: 1 1 auto !important;
                justify-content: flex-start !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-pills {
                order: 2 !important;
                gap: 5px !important;
                padding: 0 !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-pill,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-day-chip,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-attempts-extra,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-attempts-toggle.filter-badge {
                min-height: 22px !important;
                height: 22px !important;
                padding: 0 8px !important;
                border-radius: 999px !important;
                font-size: 9px !important;
                line-height: 1 !important;
                white-space: nowrap !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-4 .filter-badge,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-5 .filter-badge {
                min-width: 0 !important;
                overflow: hidden !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-4 .filter-badge i,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-5 .filter-badge i {
                flex: 0 0 auto !important;
                font-size: 9px !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-4 .filter-badge-label,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-5 .filter-badge-label {
                min-width: 0 !important;
                overflow: hidden !important;
                text-overflow: ellipsis !important;
                white-space: nowrap !important;
                font-size: 10.2px !important;
                line-height: 1.1 !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-4 .filter-badge.filter-module {
                --workspace-tile-bg: #fffaf2 !important;
                --workspace-tile-border: #fde3bf !important;
                --workspace-tile-text: #c56a1b !important;
                --workspace-tile-bg-active: #ffedd5 !important;
                --workspace-tile-border-active: #fdba74 !important;
                --workspace-tile-text-active: #9a3412 !important;
                --workspace-tile-shadow: 0 8px 18px rgba(191, 127, 114, 0.11) !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-4 .filter-badge.filter-lesson {
                --workspace-tile-bg: #faf7ff !important;
                --workspace-tile-border: #e4dafd !important;
                --workspace-tile-text: #6e43cc !important;
                --workspace-tile-bg-active: #ede9fe !important;
                --workspace-tile-border-active: #c4b5fd !important;
                --workspace-tile-text-active: #5b21b6 !important;
                --workspace-tile-shadow: 0 8px 18px rgba(132, 116, 190, 0.11) !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-5 .filter-badge.filter-faculty {
                --workspace-tile-bg: #fbfdff !important;
                --workspace-tile-border: #d8e2ec !important;
                --workspace-tile-text: #526273 !important;
                --workspace-tile-bg-active: #eef2f7 !important;
                --workspace-tile-border-active: #b8c4d4 !important;
                --workspace-tile-text-active: #334155 !important;
                --workspace-tile-shadow: 0 8px 18px rgba(148, 163, 184, 0.13) !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-5 .filter-badge.filter-rotation {
                --workspace-tile-bg: #f2fdff !important;
                --workspace-tile-border: #c8f3f8 !important;
                --workspace-tile-text: #12736f !important;
                --workspace-tile-bg-active: #dff7f8 !important;
                --workspace-tile-border-active: #7dd3d8 !important;
                --workspace-tile-text-active: #0f5f59 !important;
                --workspace-tile-shadow: 0 8px 18px rgba(115, 173, 179, 0.13) !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-5 .filter-badge.filter-year {
                --workspace-tile-bg: #f4f9ff !important;
                --workspace-tile-border: #cfe2ff !important;
                --workspace-tile-text: #2457c5 !important;
                --workspace-tile-bg-active: #dbeafe !important;
                --workspace-tile-border-active: #93c5fd !important;
                --workspace-tile-text-active: #1e40af !important;
                --workspace-tile-shadow: 0 8px 18px rgba(107, 133, 194, 0.13) !important;
            }
        }

        html body.dark-theme.qcm-workspace-active .app-global-top-bar,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-host,
        html body.dark-theme.qcm-workspace-active #quiz-top-unified-card,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-1,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-2,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-3,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-4,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-1,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-2,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-3,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-4,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-5,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-6,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-7,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-8,
        html body.dark-theme.qcm-workspace-active #main-content,
        html body.dark-theme.qcm-workspace-active #setup-section.test-workspace-active,
        html body.dark-theme.qcm-workspace-active #quiz-panel.test-workspace,
        html body.dark-theme.qcm-workspace-active #quiz-main-column,
        html body.dark-theme.qcm-workspace-active #quiz-info-column,
        html body.dark-theme.qcm-workspace-active #study-quiz-content,
        html body.dark-theme.qcm-workspace-active #quiz-container,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container,
        html body.dark-theme.qcm-workspace-active #question-card-wrapper,
        html body.dark-theme.qcm-workspace-active #question-card,
        html body.dark-theme.qcm-workspace-active #question-card .question-card-body {
            background: #0b1220 !important;
            background-image: none !important;
            border: none !important;
            box-shadow: none !important;
        }

        html body.dark-theme.qcm-workspace-active #question-card-wrapper,
        html body.dark-theme.qcm-workspace-active #question-card,
        html body.dark-theme.qcm-workspace-active #question-card .question-card-body,
        html body.dark-theme.qcm-workspace-active #auto-explanation-container.auto-explanation,
        html body.dark-theme.qcm-workspace-active #auto-explanation-container .explanation-header,
        html body.dark-theme.qcm-workspace-active #auto-explanation-content {
            background: #0d1628 !important;
            background-image: none !important;
            border: none !important;
            box-shadow: none !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn {
            background: rgba(15, 23, 42, 0.24) !important;
            background-image: none !important;
            border: none !important;
            border-left: 3px solid transparent !important;
            box-shadow: none !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn:hover,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn:hover {
            background: rgba(30, 41, 59, 0.46) !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-current,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-current {
            background: rgba(37, 99, 235, 0.14) !important;
            border-left-color: rgba(96, 165, 250, 0.9) !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-correct,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-correct {
            background: rgba(22, 163, 74, 0.14) !important;
            border-left-color: rgba(74, 222, 128, 0.9) !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-overdue,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-overdue {
            background: rgba(245, 158, 11, 0.14) !important;
            border-left-color: rgba(251, 191, 36, 0.9) !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-current.is-wrong,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-current.is-wrong,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result="wrong"],
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result="wrong"] {
            background: rgba(127, 29, 29, 0.18) !important;
            background-image: none !important;
            border: none !important;
            border-left: 3px solid rgba(248, 113, 113, 0.74) !important;
            box-shadow: none !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-index {
            background: rgba(148, 163, 184, 0.12) !important;
            border: none !important;
            box-shadow: none !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-current.is-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-current.is-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result="wrong"] .nav-instruction-index {
            background: rgba(248, 113, 113, 0.12) !important;
            border: none !important;
        }

        html body.dark-theme.qcm-workspace-active #question-stats .question-stats-main-frame,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-main-frame {
            background: #0d1628 !important;
            border: 1px solid rgba(71, 85, 105, 0.44) !important;
            box-shadow: none !important;
        }

        html body.dark-theme.qcm-workspace-active #question-stats .question-day-chip.empty,
        html body.dark-theme.qcm-workspace-active #question-stats .question-attempts-empty,
        html body.dark-theme.qcm-workspace-active #question-stats #révision-count,
        html body.dark-theme.qcm-workspace-active #question-stats .question-attempts-toggle.filter-badge {
            background: #0d1628 !important;
            border-color: rgba(71, 85, 105, 0.48) !important;
            color: #dbe7f5 !important;
            -webkit-text-fill-color: #dbe7f5 !important;
            box-shadow: none !important;
        }

        /* FINAL LAST-LOADED LOCK (2026-04-22): mobile workspace parity + dark flattening */
        @media (max-width: 768px) {
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-compact-row {
                width: 100% !important;
                min-width: 0 !important;
                overflow: visible !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-compact-row,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-main-frame {
                display: flex !important;
                align-items: center !important;
                flex-wrap: nowrap !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-main-frame {
                width: 100% !important;
                max-width: 100% !important;
                min-width: 0 !important;
                justify-content: flex-start !important;
                gap: 5px !important;
                padding: 5px 10px !important;
                border: 1.5px solid #74b0df !important;
                border-radius: 999px !important;
                background: linear-gradient(180deg, #97cff8 0%, #87c2ef 100%) !important;
                box-shadow: 0 10px 22px rgba(114, 164, 215, 0.18) !important;
                overflow-x: auto !important;
                overflow-y: hidden !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats #révision-details,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-pills,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-attempts-dropdown {
                display: inline-flex !important;
                align-items: center !important;
                justify-content: center !important;
                flex: 0 0 auto !important;
                min-width: 0 !important;
                width: auto !important;
                overflow: visible !important;
                white-space: nowrap !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats #révision-details {
                order: 1 !important;
                flex: 1 1 auto !important;
                justify-content: flex-start !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-pills {
                order: 2 !important;
                gap: 5px !important;
                padding: 0 !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-pill,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-day-chip,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-attempts-extra,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-attempts-toggle.filter-badge {
                min-height: 22px !important;
                height: 22px !important;
                padding: 0 8px !important;
                border-radius: 999px !important;
                font-size: 9px !important;
                line-height: 1 !important;
                white-space: nowrap !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-4 .filter-badge,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-5 .filter-badge {
                min-width: 0 !important;
                overflow: hidden !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-4 .filter-badge i,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-5 .filter-badge i {
                flex: 0 0 auto !important;
                font-size: 9px !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-4 .filter-badge-label,
            html body.qcm-workspace-active #workspace-topbar-mobile-line-5 .filter-badge-label {
                min-width: 0 !important;
                overflow: hidden !important;
                text-overflow: ellipsis !important;
                white-space: nowrap !important;
                font-size: 10.2px !important;
                line-height: 1.1 !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-4 .filter-badge.filter-module {
                --workspace-tile-bg: #fffaf2 !important;
                --workspace-tile-border: #fde3bf !important;
                --workspace-tile-text: #c56a1b !important;
                --workspace-tile-bg-active: #ffedd5 !important;
                --workspace-tile-border-active: #fdba74 !important;
                --workspace-tile-text-active: #9a3412 !important;
                --workspace-tile-shadow: 0 8px 18px rgba(191, 127, 114, 0.11) !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-4 .filter-badge.filter-lesson {
                --workspace-tile-bg: #faf7ff !important;
                --workspace-tile-border: #e4dafd !important;
                --workspace-tile-text: #6e43cc !important;
                --workspace-tile-bg-active: #ede9fe !important;
                --workspace-tile-border-active: #c4b5fd !important;
                --workspace-tile-text-active: #5b21b6 !important;
                --workspace-tile-shadow: 0 8px 18px rgba(132, 116, 190, 0.11) !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-5 .filter-badge.filter-faculty {
                --workspace-tile-bg: #fbfdff !important;
                --workspace-tile-border: #d8e2ec !important;
                --workspace-tile-text: #526273 !important;
                --workspace-tile-bg-active: #eef2f7 !important;
                --workspace-tile-border-active: #b8c4d4 !important;
                --workspace-tile-text-active: #334155 !important;
                --workspace-tile-shadow: 0 8px 18px rgba(148, 163, 184, 0.13) !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-5 .filter-badge.filter-rotation {
                --workspace-tile-bg: #f2fdff !important;
                --workspace-tile-border: #c8f3f8 !important;
                --workspace-tile-text: #12736f !important;
                --workspace-tile-bg-active: #dff7f8 !important;
                --workspace-tile-border-active: #7dd3d8 !important;
                --workspace-tile-text-active: #0f5f59 !important;
                --workspace-tile-shadow: 0 8px 18px rgba(115, 173, 179, 0.13) !important;
            }

            html body.qcm-workspace-active #workspace-topbar-mobile-line-5 .filter-badge.filter-year {
                --workspace-tile-bg: #f4f9ff !important;
                --workspace-tile-border: #cfe2ff !important;
                --workspace-tile-text: #2457c5 !important;
                --workspace-tile-bg-active: #dbeafe !important;
                --workspace-tile-border-active: #93c5fd !important;
                --workspace-tile-text-active: #1e40af !important;
                --workspace-tile-shadow: 0 8px 18px rgba(107, 133, 194, 0.13) !important;
            }
        }

        html body.dark-theme.qcm-workspace-active .app-global-top-bar,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-host,
        html body.dark-theme.qcm-workspace-active #quiz-top-unified-card,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-1,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-2,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-3,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-row-4,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-1,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-2,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-3,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-4,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-5,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-6,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-7,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-8,
        html body.dark-theme.qcm-workspace-active #main-content,
        html body.dark-theme.qcm-workspace-active #setup-section.test-workspace-active,
        html body.dark-theme.qcm-workspace-active #quiz-panel.test-workspace,
        html body.dark-theme.qcm-workspace-active #quiz-main-column,
        html body.dark-theme.qcm-workspace-active #quiz-info-column,
        html body.dark-theme.qcm-workspace-active #study-quiz-content,
        html body.dark-theme.qcm-workspace-active #quiz-container,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container,
        html body.dark-theme.qcm-workspace-active #question-card-wrapper,
        html body.dark-theme.qcm-workspace-active #question-card,
        html body.dark-theme.qcm-workspace-active #question-card .question-card-body {
            background: #0b1220 !important;
            background-image: none !important;
            border: none !important;
            box-shadow: none !important;
        }

        html body.dark-theme.qcm-workspace-active #question-card-wrapper,
        html body.dark-theme.qcm-workspace-active #question-card,
        html body.dark-theme.qcm-workspace-active #question-card .question-card-body,
        html body.dark-theme.qcm-workspace-active #auto-explanation-container.auto-explanation,
        html body.dark-theme.qcm-workspace-active #auto-explanation-container .explanation-header,
        html body.dark-theme.qcm-workspace-active #auto-explanation-content {
            background: #0d1628 !important;
            background-image: none !important;
            border: none !important;
            box-shadow: none !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn {
            background: rgba(15, 23, 42, 0.24) !important;
            background-image: none !important;
            border: none !important;
            border-left: 3px solid transparent !important;
            box-shadow: none !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn:hover,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn:hover {
            background: rgba(30, 41, 59, 0.46) !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-current,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-current {
            background: rgba(37, 99, 235, 0.14) !important;
            border-left-color: rgba(96, 165, 250, 0.9) !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-correct,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-correct {
            background: rgba(22, 163, 74, 0.14) !important;
            border-left-color: rgba(74, 222, 128, 0.9) !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-overdue,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-overdue {
            background: rgba(245, 158, 11, 0.14) !important;
            border-left-color: rgba(251, 191, 36, 0.9) !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-current.is-wrong,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-current.is-wrong,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result="wrong"],
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result="wrong"] {
            background: rgba(127, 29, 29, 0.18) !important;
            background-image: none !important;
            border: none !important;
            border-left: 3px solid rgba(248, 113, 113, 0.74) !important;
            box-shadow: none !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-index {
            background: rgba(148, 163, 184, 0.12) !important;
            border: none !important;
            box-shadow: none !important;
        }

        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-current.is-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-current.is-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #sidebar-nav.test-workspace-sidebar #nav-items-container .nav-instruction-btn[data-nav-result=\"wrong\"] .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn.is-nav-wrong .nav-instruction-index,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container .nav-instruction-btn[data-nav-result=\"wrong\"] .nav-instruction-index {
            background: rgba(248, 113, 113, 0.12) !important;
            border: none !important;
        }

        html body.dark-theme.qcm-workspace-active #question-stats .question-stats-main-frame,
        html body.dark-theme.qcm-workspace-active #workspace-topbar-mobile-line-3 #question-stats .question-stats-main-frame {
            background: #0d1628 !important;
            border: 1px solid rgba(71, 85, 105, 0.44) !important;
            box-shadow: none !important;
        }

        html body.dark-theme.qcm-workspace-active #question-stats .question-day-chip.empty,
        html body.dark-theme.qcm-workspace-active #question-stats .question-attempts-empty,
        html body.dark-theme.qcm-workspace-active #question-stats #révision-count,
        html body.dark-theme.qcm-workspace-active #question-stats .question-attempts-toggle.filter-badge {
            background: #0d1628 !important;
            border-color: rgba(71, 85, 105, 0.48) !important;
            color: #dbe7f5 !important;
            -webkit-text-fill-color: #dbe7f5 !important;
            box-shadow: none !important;
        }

        html body.dark-theme.qcm-workspace-active #question-stats .question-stats-main-frame {
            background: linear-gradient(180deg, #162033 0%, #0f172a 100%) !important;
            border: 1.5px solid rgba(96, 165, 250, 0.24) !important;
            border-radius: 999px !important;
        }

        html body.dark-theme.qcm-workspace-active #question-stats .question-stats-main-frame,
        html body.dark-theme.qcm-workspace-active #question-stats .question-stats-days,
        html body.dark-theme.qcm-workspace-active #question-stats .question-stats-pills {
            scrollbar-color: rgba(96, 165, 250, 0.42) rgba(15, 23, 42, 0.92) !important;
        }

        html body.dark-theme.qcm-workspace-active #question-stats .question-stats-main-frame::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active #question-stats .question-stats-days::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active #question-stats .question-stats-pills::-webkit-scrollbar-track {
            background: rgba(15, 23, 42, 0.92) !important;
        }

        html body.dark-theme.qcm-workspace-active #question-stats .question-stats-main-frame::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active #question-stats .question-stats-days::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active #question-stats .question-stats-pills::-webkit-scrollbar-thumb {
            background: rgba(96, 165, 250, 0.42) !important;
            border: 1px solid rgba(125, 211, 252, 0.24) !important;
            border-radius: 999px !important;
        }

        html body.dark-theme.qcm-workspace-active #auto-explanation-container.auto-explanation {
            background: linear-gradient(180deg, #111827 0%, #0f172a 100%) !important;
            border: 1.5px solid rgba(96, 165, 250, 0.2) !important;
            box-shadow: 0 24px 60px rgba(2, 6, 23, 0.42) !important;
        }

        html body.dark-theme.qcm-workspace-active #auto-explanation-container .explanation-header,
        html body.dark-theme.qcm-workspace-active #auto-explanation-content,
        html body.dark-theme.qcm-workspace-active #auto-explanation-content * {
            background: transparent !important;
            color: #e5eefc !important;
        }

        html body.dark-theme.qcm-workspace-active #main-content,
        html body.dark-theme.qcm-workspace-active #setup-section.test-workspace-active,
        html body.dark-theme.qcm-workspace-active #quiz-info-column,
        html body.dark-theme.qcm-workspace-active #question-card-wrapper,
        html body.dark-theme.qcm-workspace-active #question-card,
        html body.dark-theme.qcm-workspace-active .question-card-body,
        html body.dark-theme.qcm-workspace-active #nav-items-container,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container {
            scrollbar-color: rgba(96, 165, 250, 0.34) rgba(15, 23, 42, 0.92) !important;
        }

        html body.dark-theme.qcm-workspace-active #main-content::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active #setup-section.test-workspace-active::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active #quiz-info-column::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active #question-card-wrapper::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active #question-card::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active .question-card-body::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active #nav-items-container::-webkit-scrollbar-track,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container::-webkit-scrollbar-track {
            background: rgba(15, 23, 42, 0.92) !important;
        }

        html body.dark-theme.qcm-workspace-active #main-content::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active #setup-section.test-workspace-active::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active #quiz-info-column::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active #question-card-wrapper::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active #question-card::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active .question-card-body::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active #nav-items-container::-webkit-scrollbar-thumb,
        html body.dark-theme.qcm-workspace-active #workspace-nav-items-container::-webkit-scrollbar-thumb {
            background: rgba(96, 165, 250, 0.34) !important;
            border-radius: 999px !important;
            border: 1px solid rgba(125, 211, 252, 0.18) !important;
        }
